finish
User-defined termination script for MATLAB
Syntax
Description
finish
executes user-specified commands when exiting.
MATLAB® calls the finish.m
script, if defined, whenever you
do one of the following.
Click the close button
on the MATLAB desktop on Microsoft® Windows® platforms or the equivalent on UNIX® platforms.
Type
quit
orexit
at the command prompt.
If an error occurs in the finish
script, then
quit
is canceled so that you can correct your
finish.m
file without losing your workspace.
Examples
Tips
Version History
Introduced before R2006a