MATLAB Function Reference
  Go to function:
    Search    Help Desk 
warning    See Also

Display warning message

Syntax

Description

warning('message') displays the text 'message' as does the disp function, except that with warning, message display can be suppressed.

warning off suppresses all subsequent warning messages.

warning on re-enables them.

warning backtrace is the same as warning on except that the file and line number that produced the warning are displayed.

warning debug is the same as dbstop if warning and triggers the debugger when a warning is encountered.

warning once displays Handle Graphics backwards compatibility warnings only once per session.

warning always displays Handle Graphics backwards compatibility warnings as they are encountered (subject to current warning state).

[s,f] = warning returns the current warning state s and the current warning frequency f as strings.

Remarks

Use dbstop on warning to trigger the debugger when a warning is encountered.

See Also

dbstop      Set breakpoints in an M-file function

disp        Display text or array

error       Display error messages



[ Previous | Help Desk | Next ]