Stupid bookmark handling of numbered itmes in word

P

periodic

I recently wrote a macro trying to replace occurrences of \[[0-9]@\] with a
cross reference to the correct item in the bibliography list.
The author had inserted all references in plain text ><

Anyway it seemed to work fine and the macro even nicely asked if it should
replace the found text with a particular cross reference. But when I tested
it out I noticed to my great irritation that if you put the insertion point
in the beginning of the bibliography list and created a new first entry in
said list. The cross references to what previously was the first entry did
not change but all other did.

So it seems that word creates a new bookmark for what has become the second
item and not the first item (which is the new one) This is just stupid
behavior from word according to me. (Im using word 2003 btw)

So in conclusion the question is: Is there a way to make this behave as it
should using words own bookmarks for numbered items. Or do I have to put my
own bookmarks where I want them to get this to work?
 
L

Lene Fredborg

If you press Return while the insertion point is in the start of an already
Ref-bookmarked paragraph, the new paragraph will be included in the existing
Ref bookmark. See the below Problem 2 at this address for information about
how to prevent the problem:
http://www.thedoctools.com/index.php?show=wt_cross-reference_trouble

--
Regards
Lene Fredborg
DocTools - Denmark
www.thedoctools.com
Document automation - add-ins, macros and templates for Microsoft Word
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top