| Contents | Index |
disp(exception)
disp(exception.property)
disp(exception) displays all properties (fields) of MException object exception.
disp(exception.property) displays the specified property of MException object exception.
Using the surf command without input arguments throws an exception. Use disp to display the identifier, message, stack, and cause properties of the MException object:
try
surf
catch exception
disp(exception)
end
MException object with properties:
identifier: 'MATLAB:narginchk:notEnoughInputs'
message: 'Not enough input arguments.'
cause: {}
stack: [1x1 struct]
Display only the stack property:
disp(exception.stack)
file: 'C:\Program Files\MATLAB\toolbox\matlab\graph3d\surf.m'
graph3d\surf.m'
name: 'surf'
line: 54addCause(MException) | assert | catch | eq(MException) | error | getReport(MException) | isequal(MException) | last(MException) | MException | ne(MException) | rethrow(MException) | throw(MException) | throwAsCaller(MException) | try
| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |