View Single Post
 
Old 07-08-2014, 03:03 AM
macropod's Avatar
macropod macropod is offline Windows 7 32bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,369
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

I assume you're using something like the solution discussed in this thread:
https://www.msofficeforums.com/word-...numbering.html
To have such macros available to all documents based on a given template (e.g. the Normal.dotm template), simply add the code to that template. I'd advise against using the Normal.dotm template for this, though, as that will impact every document you create - better to create a specific template for all the barcode documents and attach that template to them. Provided the template is stored in a location to which all users of the documents have at least read access, they'll have access to the macros as well.

The only way around manually adding the DOCVARIABLE field would be to write a macro to do it. That macro might sit in the same template as mentioned above and, once the attaching of a particular document is done, which requires opening the document, simply run the macro to add the field to the header.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote