What's new

api, programmatically change a parameter in an open part

cdub

Member
api, programmatically change a parameter in an open part

Does anyone have some sample api code that does the following:

Looks at a part that is open in session and changes a parameter in that part, say D1.

Forces a regen of the part.

I think I have the regen part completed:
objADDesignSession = objADSession
Call objADDesignSession.RegenerateDesign(True)

Thank you,
cdub
 

alexfranke

Senior Member


Yes, in fact I'm working on an API app that does ths very thing, but for sets of parameters and parts.

I can get you some code later, but to start, just remember to call [Begin/End]ParameterTransaction() before and after the change. The lack of parameter examples in the documentation makes this easy to miss...

Good luck -- let me know if there's anything I can help you with!
-Alex
 

cdub

Member
change parameter, - mess with configs?

Alex,

Thank you for the tip! That's just the thing I was looking for.

cdub

Have you had any luck with using configurations through the API? Like creating, activating, modifing, etc?

I see the commands in there, and I've been able to create and name new, but not activate it.

Thank you,
cdub
 
Top