Skip navigation
Currently Being Moderated

Delete an anchored and tagged picture frame

Jul 24, 2012 5:33 AM

Tags: #tags #graphic_frame #inline

Hi everybody,

 

I have a picture frame anchored in a story. This picture frame is tagged. I need to delete it.

 

For this purpose, I can get access to the XMLReference of the tag through an Id. From here, I tried unsucessfully to delete the xml element (IXMLElementCommands::DeleteElement(...)), or delete the content inside the element (ITextModelCmds::DeleteCmd(...) after retrieving the range with IXMLUtils::GetElementIndices(...) or IXMLUtils::GetElementMarkerPositions(...)), or both of them. In each case, at the closure of the document, I have asserts :

"~InstanceList(): 1 outstanding references to UID 170 (Class kSBOSPageBoss)."

 

It is as if there were still a reference on the deleted anchored frame. In the solution guide, it just tells to delete the anchored character to delete the associated anchored frame. Did I miss something ?

 

Something weird is that IXMLUtils::GetElementIndices(...) or IXMLUtils::GetElementMarkerPositions(...) give me start index at 0 and end index at -1. However, the xml element is found...

 
Replies

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points