Log In | Not a Member? | Support | |
SYNTAX
GetErrorText [errorNumber1[,insert1] [errorNumber2][,insert2]… DESCRIPTION The GetErrorText tool displays the error messages corresponding to one or more error or ID numbers. There are two types of error numbers in MPW: those corresponding to the Mac OS and those corresponding to an individual tool. Normally GetErrorText assumes the former, but you can specify a file containing error messages for the latter by using the -f option. In addition to displaying messages for error numbers, GetErrorText can also display messages for ID numbers reported by the System Error Handler in alerts (-i). INPUT An error or ID number. GetErrorText does not accept standard input. OUTPUT Standard output. GetErrorText writes error messages for the specified error or ID numbers to standard output. STATUS
GetErrorText can return the following status codes:
PARAMETERS errorNumber1 [errorNumber2]… Specifies one or more error numbers. Normally GetErrorText assumes these are error numbers from the Mac OS. In this case MPW retrieves the messages from the file SysErrs.Err. See -s to specify a different system message file. ,insert1[,insert2]… Specifies sample inserts to go with error messages corresponding to tool error numbers. Note that you must use a comma before this parameter and that you must also specify -f. The insert replaces a carat (^) in the error message. OPTIONS -f filename Specifies a tool's error message filename. This allows you to display error messages for an individual tool rather than for the system. For example, the assembler's error message file is in the data fork of Asm itself. Note that this is an alternative to displaying system error messages; therefore you can specify either -f or -s, but not both. -i idNumber1 [idNumber2]… Displays error messages corresponding to the system idNumbers you specify, as they appear in alert dialogs.
Note -n Inhibits generating error numbers as part of the error messages. The GetErrorText tool ignores this option when displaying system errors. -p Writes version information to diagnostic output. -s filename Specifies the error message filename for a system error. This overrides the default system error file, SysErrs.Err. Note that you cannot specify this option in conjunction with -f. EXAMPLES The command line GetErrorText -43 -44 -45 displays the error messages for system errors -43, -44, and -45 as follows:
File not found (OS error - 43) The command line GetErrorText -i 1 4 displays the error messages corresponding to system ID numbers 1 and 4 in the following format:
Bus error: invalid memory reference (System error 1)
|