EMSG

From STX Wiki
< Programmer Guide‎ | Command Reference
Revision as of 15:05, 17 May 2010 by 193.171.195.8 (talk) (initial import)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

EMSG

#emsg := EMSG errorCode|table

The EMSG command will return a string describing the meaning of a numerical error (errorCode) returned by an S_TOOLS-STx command. If a table item (table) is passed instead of an error code, all error descriptions are stored in the table (deleting the previous contents).

// store all error messages in a simple table
#tab := new table *
EMSG $#tab

or

// check if command fails and display error message on error
#spu := new spu * testspu pa pb pc
if '$rc' > 0 em $rc ; SPU creation failed: $(emsg $rc)

Navigation menu

Personal tools