How can I interrupt a callback and NOT come back to finish its execution in MATLAB?
Show older comments
I have a GUI with a callback. When the callback is interrupted during a loop, the interrupting function executes and then MATLAB returns to finish the execution of the interrupted callback. I would like MATLAB to exit the original loop once the interrupting function has finished executing.
I have tried setting the 'Interruptible' and 'BusyAction' properties of the UICONTROL to all different combinations, and nothing seemed to help.
For example, in the attached file 'testinterrupt', after entering the 1st loop, if I press the pushbutton again, MATLAB will enter loop 2, but return and finish loop 1 after loop 2 is done executing.
Accepted Answer
More Answers (0)
Categories
Find more on Loops and Conditional Statements in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!