PROGRAM QIOERR C C A program to translate QIO error messages. Input is C the QIO error number, output is the message from the C system message file. C C B. Z. Lederman C IMPLICIT INTEGER (A-Z) BYTE MSG (64) C C Open the system QIO error message file. C OPEN (UNIT = 1, FILE = 'LB:[1,2]QIOSYM.MSG', STATUS = 'OLD', 1 READONLY, ACCESS = 'DIRECT', FORM = 'UNFORMATTED', 2 RECORDSIZE = 16) C C Prompt user for an error number (decimal). C 10 WRITE (5, 100) 100 FORMAT('$ Enter error number (decimal, positive): ') READ (5, 110, END = 500) I 110 FORMAT (I5) C C Next part is easy. Error number is record number in file. C READ (1'I) MSG C C Convert the error number to a byte octal value C I = -I J = IAND(I, '377'O) C C Write out the octal error number with the text C WRITE (5, 120) I, J, MSG 120 FORMAT( 1X, I6, 1X, O3, 1X, 64A1) GOTO 10 C 500 CLOSE (UNIT = 1) STOP END