Community
PowerMill Forum
Welcome to Autodesk’s PowerMill Forums. Share your knowledge, ask questions, and explore popular PowerMill topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Macro Help

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
Beta_Librae
327 Views, 2 Replies

Macro Help

Salutations all,

 

I'm looking for some help with the command to call the active state of the stock model.

Right now I'm calling it out as state '1', state '2', and so on...

Beta_Librae_0-1714065619820.png

I just came across a situation where I didn't want to run in that order. Had to export the stock model and bring it back in to get the macro to run at the proper state.

Any help would be greatly appreciated!


Kind Regards,
Not cnc, you can call me Peabrain
2 REPLIES 2
Message 2 of 3
Sean571
in reply to: Beta_Librae

This gets the active state of the active stock model, but this will take awhile to run on large stock models, so keep that in mind.

string activeState = filter(entity('stockmodel', '').States, "this.Active")[0].name	

 

Sean Wroblewski
Applications Engineer


Message 3 of 3
Beta_Librae
in reply to: Sean571

Hey Sean,

 

Thanks for the reply. Greatly appreciated. I haven't had a chance to implement it yet, but this is for a roughing macro, the stock model will never be too big, I'm not to worried that it'll take long.


Kind Regards,
Not cnc, you can call me Peabrain

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Technology Administrators


Autodesk Design & Make Report