I have document (A) which contains some macros. In another document (B)
I am dynamically creating a CommandBarButton using VBAs AutoOpen
procedure. The buttons OnAction property should now call a macro from
the document A. But even if both documents are open, the macros in A
seem not to be visible???
How should the OnAction string look like? or do you see other posibilities?
Thanks in advance!
Luc
Jonathan West - 26 Nov 2004 12:27 GMT
>I have document (A) which contains some macros. In another document (B) I
>am dynamically creating a CommandBarButton using VBAs AutoOpen procedure.
[quoted text clipped - 5 lines]
> Thanks in advance!
> Luc
From one macro, you can call a macro in another open document or template
using the Application.Run method. There are details in the VBA Help.

Signature
Regards
Jonathan West - Word MVP
www.intelligentdocuments.co.uk
Please reply to the newsgroup