Announcements

The Autodesk Community Forums has a new look. Read more about what's changed on the Community Announcements board.

Initialising a vba macro in every new part

fisaVMY4M
Explorer

Initialising a vba macro in every new part

fisaVMY4M
Explorer
Explorer

Hallo,

Is there a way to install a vba macro in inventor so that every new part or assembly has it?

 

Thanks for the answers.

 

Greetings 

0 Likes
Reply
Accepted solutions (1)
369 Views
4 Replies
Replies (4)

l_dalise
Participant
Participant

If I understand you correctly, you want to create a macro that every new file must contain, right?
You can insert the macro in the .ipt or .iam template model, so every new part created has the macro

And if you need it to be initialized when you open the document or when you create a new file, you can put that macro (or rule) in the Event Trigger

0 Likes

fisaVMY4M
Explorer
Explorer

Yeah eather way would be fine. I created a macro already but failed to put it in the template. Do you know in which folder i need to put it?

 

And if you could provide me with infos about the integration with an event trigger i would be happy too.

Thanks alot and have a good weekend.

0 Likes

fisaVMY4M
Explorer
Explorer
Accepted solution

Got it. I just put it in the application project.

bradeneuropeArthur
Mentor
Mentor

Maybe this is of the topic, but by experience I would advice to create a add-in for these circumstances/cases.

Regards,

Arthur Knoors

Autodesk Affiliations:

Autodesk Software:Inventor Professional 2025 | Vault Professional 2024 | Autocad Mechanical 2024
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:Drawing List!|Toggle Drawing Sheet!|Workplane Resize!|Drawing View Locker!|Multi Sheet to Mono Sheet!|Drawing Weld Symbols!|Drawing View Label Align!|Open From Balloon!|Model State Lock!
Posts and Ideas:Dimension Component!|Partlist Export!|Derive I-properties!|Vault Prompts Via API!|Vault Handbook/Manual!|Drawing Toggle Sheets!|Vault Defer Update!


! For administrative reasons, please mark a "Solution as solved" when the issue is solved !

0 Likes