I am working on a software which reads several Word documents and merges them. Each document has a text (a TextBox) in its Header. When creating the final document, I find that text, create a TC field for that, insert it into the document, update the Table Of Contents. I do it because Word can not create a TOC based on the Header or Footer contents.
This works fine until the header text is modified by the user. If the text is modified, TC fields needs to be updated accordingly. My question is that how can I write a macro that if the text of the text box (which is in Page Header) is changed, the matching TC field is found and its text property is updated? This might happen when the document is saved.
This link describes the source of this requirement:
helps are highly appreciated.