Quote:
Originally Posted by Kalü
I attached a Word2010 document as example. It works all fine, only after "1. Heading xy" the number 1.1 in the following paragraph becomes highlighted (after pasting in a new document and running the second macro).
You can also see it at the tags, that end after 1.1 and not after Heading xy as they should. Is this maybe because of the automatic numbering?
|
That's because the bold/italic formatting is applied to the paragraph break in your document and, to faithfully replicate that, the formatting code has to follow the paragraph break - just as it does with any other text. It has no effect on the final result for the following paragraph, though - after running the second macro, the original formatting is restored. In any event, the comments at the end of the post show how to prevent paragraphs breaks being tagged.