I do see how to attach a macro to a button. I see now that there is a Macro category on the Commands tab of customize toolbars. So the remaining question is why am I getting a "requested object is not available" message when I execute my macro?
If I perform the exact same steps while not recording a macro, my template opens up a new document as expected and the merge data button is available. If I record these exact same steps, I get the "requested object is not available" debug on the last statement of my code (ActiveDocument.MailMerge.ViewMailMergeFieldCodes = wdToggle) which should merge the data into the document. The merge button is greyed out and not available to do manually either.
|