cancel
Showing results for 
Search instead for 
Did you mean: 

Trigger macro on diagram save/dispatch

Solved
New Contributor

Trigger macro on diagram save/dispatch

Hi,

 

How do you trigger a macro when a diagram is saved/dispatched?

i.e. we would like to save the diagram as a png when it changes.

 

I can't seem to find any documentation on this.

 

Thanks

2 Replies
Regular Contributor

Re: Trigger macro on diagram save/dispatch

you need to create a diagram plugin with a sub

Sub OnSaveDrawing( oDrawing As MegaDrawing )

End Sub

it's all described in the pdf Diagram API tutorial. The script will fire when the diagram is saved by the user.

New Contributor

Re: Trigger macro on diagram save/dispatch

Thanks. Found the documentation.

Search for 'OnSaveDrawing' in here:

http://community.mega.com/mega/attachments/mega/HOPEXV1R2/10/68/All%20about%20starting%20with%20APIs...