WPCubed Product Support

FEDPOL #74 - Overlapping bookmarks

We have a lot of Word 97 documents that contain overlapping bookmarks. When we load these documents as RTF into WPTools then the start/end tags of those overlapping bookmarks are not correctly matched. This is a problem because we need to extract the text between the start/end tags of those bookmarks. As far as I could see WPTools does not use the bookmark names to match start/end tags when loading the document. In the example below this causes start tag "BM1" to be matched with end tag "BM2" and vice versa.

{\*\bkmkstart BM1}{\*\bkmkstart BM2}{\*\bkmkend BM1}hello world{\*\bkmkend BM2}
#1 ♥ 0
3.5k Views 2 users read 1 min
support

WPTools will not do this overlapping bookmarks. When writing text it will also always close open bookmarks. The edit functions will not allow the creation of this overlapping bookmarks, but nesting bookmarks is ok as advertised.

#3 ♥ 0

I fixed this WPTools bug myself by modifying TWPTextObj.EndTag (from top of my head, hope this is correct) so that end tags for bookmarks are matched using its name.

#4 ♥ 0
This category is archived. No new posts are possible.