fusion 360, api, python, refresh/update/save after parametric change

fusion 360, api, python, refresh/update/save after parametric change

andrew
Explorer Explorer
794 Views
2 Replies
Message 1 of 3

fusion 360, api, python, refresh/update/save after parametric change

andrew
Explorer
Explorer

Good afternoon:)

I have a python script which seems correct.

It generates a number of STEP files from one parametric model.

I think some semaphore that the model has been updated is required. I cannot locate it.

 

The result should be a collection of STEP files describing differing parts, the collection has parts which are the same so i do not trust the process yet. My guess is a synchronization problem.

I do expect the image of the model to change on screen, this does not occur reliably.

 

Searches have not lead me to a solution.

 

Prompt help would be very welcome.

 

Regards Andrew

0 Likes
Accepted solutions (1)
795 Views
2 Replies
Replies (2)
Message 2 of 3

Jorge_Jaramillo
Collaborator
Collaborator
Accepted solution
Hi,
Not sure if I understand you well with your description.
If you are running a script that takes longer to execute and makes many changes to the model, calling adsk.doEvents() many times during its execution (inside main loops), will refresh the model.

Hope this could help yout out.
Message 3 of 3

andrew
Explorer
Explorer

Thanks Jorge 🙂

your solution works for my purposes. 
happy boy here 🙂

0 Likes