MESG, a simple System Message viewer, by Joe Horn --> S/SX/G/GX chana1@elaine.ee.und.ac.za [AMISH CHANA : EC-THIRD] writes: > Does anyone know how to display the built-in messages on the GX. > Using the "DOERR" command displays the message but places "ERROR" on > the top line. I want to display a message, in a program, but without > "ERROR" on the top line. to which v076l7zh@ubvms.cc.buffalo.edu [Howard S Schumacher] replies: > There is no way to do it. Sure there is! In User RPL: << IFERR DOERR THEN ERRM END >> BYTES: #9C6h 22.5 INPUT: desired error number (either a real or a binary integer). OUTPUT: error message as a string. Drawbacks: (1) Doesn't error out properly if given a bad input type or no argument. (2) Kinda slow. In System RPL: :: CK1NOLASTWD CK&DISPATCH1 ONE :: COERCE JstGETTHEMSG ; ELEVEN :: HXS># JstGETTHEMSG ; ; BYTES: #2B61h 35.0 INPUT: desired error number (either a real or a binary integer). OUTPUT: error message as a string. Benefits: (1) Handles bad/no input correctly. (2) Ten times faster. Note: On the G/GX, there are far more messages available than listed in the manuals. The existing message range (in hex) is: 1st - Lst | Description ----------+---------------------------------------- 0001-0010 | Panic 0101-013D | Don't Panic 0201-0208 | Stack & EquationWriter 0301-0305 | Range errors 0501-0506 | Array ops 0601-062E | STAT, PLOT, SOLVE, Alarms, I/O ops 0A01-0A09 | SOLVE, PLOT 0B01-0B02 | UNITS 0C01-0C17 | I/O messages 0D01-0D04 | TIME B901-B99B | System Input Forms, MODES, MEMORY BA01-BA43 | I/O input form BB01-BB3F | STAT input form BC01-BC3B | TIME input forms (incl. days & months) BD01-BD27 | SYMBOLIC input forms BE01-BE77 | PLOT input forms BF01-BF56 | SOLVE input forms C001 ---- | PROOT (Unable to find root) E101-E129 | CONLIB constants E301-E304 | EQNLIB E401-E408 | MSOLVR E601-E60D | TVM E701-E706 | MINEHUNT Note that the first two digits of the hex message number are a library ID number, and the last two digits are the number of the entry within that library's message table. Thus #E706 is message #6 in library #E7 ("YOU BLEW UP!!" in the Minehunt game). This concept also applies to libraries in ports, e.g. the Periodic Table Library has an ID of 703 (hex #2BF) so #2BF01 yields its first message. WHOA! Be careful! I just tried to recall message #31103h (in the Math Pac from Sparcom), and *wham*, it nuked all my memory! Even the innocent-looking User RPL command #31103h DOERR will cause a psychotic display of random pixels as your memory is being cleared, if you have the Sparcom Math Pac installed. No doubt they "cheated" and stored something other than normal text there. Clever... but unwise. -Joseph K. Horn-