Running Embedded Macros

Hello.

 

Is it possible to run a macro embedded with in document from a different gms file?

 

To clarify the situation, I am beginning a project where individual templates will have their own macros for automated building. I would like to have a separate macro or program (probably written in C#) open the appropriate document and pass in values pulled from a report of orders. However, I would also like to be able to use the individual macros separately if it is needed, and there is a potential of over 300 unique templates.

 

OberonPlace seems to not be allowing registrations right now, so I was hoping to find a bit of help here.

 

Thanks for your help!

  • I do not believe this is possible.

    If it were I would also not recommend this approach. These days because of security it is not a good idea to have your code in the actual document. Also the user may have chosen not to Enable Macros on the security warning and that would prevent it running for sure.

    You can call code from one GMS from another if you like.

    GMSManager.RunMacro "GlobalMacros", "MyModule.MyTestSub"

    Hopefully that helps a little.

    -Shelby