View Single Post
  #2   Report Post  
Peter Jamieson
 
Posts: n/a
Default

I've never worked out exactly what Word does with the attached template
during a merge, but in some cases the template seems to remain attached tot
he newly created document, in others it is attached but the macros are
unavailable, etc.

There are a couple of things you could try...
a. set up the macros you want in a template that you load as an addin - its
macros should then be available to everyone all the time. Requires some
admin work though
b. create a macro that does the merge and re-connects the output document
to the template. Attach the macro to a toolbar button and get the users to
use that to initiate the merge (you can try intercepting the existing
commands but personally I think it is confusing to alter the functions of
standard buttons).

BTW I would be wary of using /templates/ with an attached mail merge data
source.

Peter Jamieson

"Al" wrote in message
...
Hi Guys

I've created a Custom Mail Merge template which looks at an Excel
spreadsheet.

The template also contains VBA to help the users once the merged document
has been created.

My problem is, whenever I carry out the 'Merge to New Document' feature,
the
mail merge executes correctly but the new document looses it's association
with the Mail Merge template and restorts to Normal.dot as the associated
template.

Therefore, this means the users no longer have access to the VBA or the
custom toolbars that the Custom Mail Merge template should provide.

Is there away around this problem other than training our users to
reattach
the custom template to the document?

All suggestions gratefully received

Regards

Alex