Changing model programmatically: discard changes and exit?
15 views (last 30 days)
Danijel Domazet on 18 May 2020
I programmatically change a model in Simulink, run the simulation, and exit.
When I run it again, I get an error from add_block() that the block already exists.
So I add
and than I can run the model again with no problem.
However, I would like to exit without saving the modified model.
Is it possible to somehow discard the changes and exit?