Programmer Guide/Macro Library/EM: Difference between revisions
From STX Wiki
Jump to navigationJump to search
(initial import) |
m (1 revision: Initial import) |
(No difference)
|
Latest revision as of 17:31, 18 November 2010
EM
A shorthand way to display an error message and exit a macro.
Usage:
EM [ eCode [ eLevel ]] ; [ eMessage ]
Parameters:
- eCode
- The error code to display (default = -1). This code is also returned to the caller.
- eLevel
- The number of macro levels to exit. This value includes exiting the
EM
macro itself. The default is 2 (i.e. the calling macro is exited).
- eMessage
- The message to display in a dialog box.
Result:
The value of eCode
Examples:
em $rc ; Failed to do whatever the previous command was trying to do