On create new file

On create new file

etfrench
Mentor Mentor
632 Views
5 Replies
Message 1 of 6

On create new file

etfrench
Mentor
Mentor

Is there a way to run a script whenever a new file is created?

ETFrench

EESignature

0 Likes
633 Views
5 Replies
Replies (5)
Message 2 of 6

Anonymous
Not applicable

I'm not too familiar with the way Fusion does its events but you might start with the Application object and this example (Sample Programs/General/Miscellaneous/Application Event API Sample). The application object help page is here), and I'm assuming those links are persistence given I've had trouble getting back using Firefox history.

 

The Application object has documentOpened and documentOpening event handlers. Whether that's the same thing as "create new file" I don't know. Possibly not...

0 Likes
Message 3 of 6

etfrench
Mentor
Mentor

Thanks for the reply.  DocumentOpening isn't the same as creating a new document.  If there were an event for document creation, a script could be created to set parameters and other settings for group projects.

ETFrench

EESignature

0 Likes
Message 4 of 6

ekinsb
Alumni
Alumni

There currently is not a specific event for when a new file is created.  However, we will be adding this in the near future along with some other document related events.


Brian Ekins
Inventor and Fusion 360 API Expert
Mod the Machine blog
0 Likes
Message 5 of 6

etfrench
Mentor
Mentor

Sounds good.  Thanks

ETFrench

EESignature

0 Likes
Message 6 of 6

ekinsb
Alumni
Alumni

Just to let you know that this capability will be in the May 30 Fusion 360 update.


Brian Ekins
Inventor and Fusion 360 API Expert
Mod the Machine blog
0 Likes