If it's a true template, it would have a dotm extension, not docm. That said, what you're describing is the normal behaviour for a document created from a template. If you want the macros to travel with the document, you'll have to add them to the document - and save it in the docm format. Although this could be done programmatically, it would require giving 'trusted access' to the VBA project environment, which is a significant security risk for you. Otherwise, you could send both the document and the template - which the recipient would need to copy to their own templates folder (not a simple task for most users) so the macros would once again be available to the document.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
|