ModelingEvents.OnParameterChange

ModelingEvents.OnParameterChange

Anonymous
Not applicable
391 Views
2 Replies
Message 1 of 3

ModelingEvents.OnParameterChange

Anonymous
Not applicable

I can't find any sample codes that use ModelingEvents.OnParameterChange.

 

I want to create a VBA macro that will fire a global rule on specific parameter change. I don't know if this is possible but any help is appriciated

 

 

ModelingEvents.OnParameterChangeDocumentObject As DocumentParameter As ParameterBeforeOrAfter As EventTimingEnumContext As NameValueMapHandlingCode As HandlingCodeEnum )

0 Likes
392 Views
2 Replies
Replies (2)
Message 2 of 3

BrianEkins
Mentor
Mentor

VBA is not very well suited for working with these types of events. Your program needs to be continually running and listening for the event. VBA is intended for macros, which you run, they do their thing and then they're done. An add-in however is perfectly suited for what you want to do. It's started by Inventor when Inventor starts and then continues to run for the entire session. It can connect to whatever events it wants at startup and the respond whenever the event is fired.

 

I just taught a class on add-ins at AU this year. You can get the accompanying paper on my website. 

 

https://ekinssolutions.com/autodesk-university-2018/

---------------------------------------------------------------
Brian Ekins
Inventor and Fusion 360 API Expert
Website/Blog: https://EkinsSolutions.com
0 Likes
Message 3 of 3

Anonymous
Not applicable

Yeah i thought that will be the answer. I am a little afraid to move to add-in programing because i think there aren't many exampales of programing codefor inventor on the net as opposed to ilogic syntax code.

 

The reason i started learning coding is to develop skeletal iAssemblies

0 Likes