MATLAB Programming Fundamentals - MathWorks

(やまだぃちぅ) #1

  • Display an appropriate message.

  • Add the first MException object to the cause field of the second.

  • Add a suggested correction to an MException object.

  • Rethrow the exception. This stops program execution and displays the error message.


Cleaning up any unwanted results of the error is also advisable. For example, close
figures that remained open after the error occurred.


Respond to an Exception
Free download pdf