I have a compiled matlab program that runs as a dos box basically (ie no GUI). Is there a way to get code to execute when someone closes the program? Specifically closing by clicking on the X?
Asked
Active
Viewed 139 times
1 Answers
0
I suggest to define a cleanup task. This will be executed whenever a function is terminated (by whatever means), so as long as closing the program is not done with a kill -9
command or similar, the code is being run.

Jonas
- 74,690
- 10
- 137
- 177