General information
Category:
Coding, syntax & commands
Title:
Word Auto: Delete after bookmark deletes bookmark
Environment versions
Network:
Windows 2003 Server
Hi all,
More Word automation stuff: code loops through 3 bookmarks in a Word template and a) deletes all the text after the bookmark to the end of the line (it is just a label for "non-automation" use) and then b) inserts some data.
Works mostly okay except for some reason the very 1st bookmark in the document gets deleted when I issued the Selection.Delete() (after extending the selection to the end of the line).
I tried moving the selection 1 char to the right before extending it to the end of the line (so as to be "off" the bookmark) but this puts the insertion point a char 2 which is not correct.
Bookmarks 2 and 3 work okay as somehow they are different.
Ideas of a workaround?
Albert
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only