PRINTER DISPLAY

PRINTER DISPLAY

Top  Previous  Next

 

The PRINTER DISPLAY statement directs output sent to a print unit to the display.

 

 

Format

 

PRINTER DISPLAY {ON print.unit}

{ON ERROR statement(s)}

{THEN statement(s)}

{ELSE statement(s)}

 

where

 

print.unit evaluates to the print unit on which the action is be to performed. If omitted, the default print unit (unit 0) is used.

 

statement(s)are statements to be executed depending on the outcome of the operation.

 

The ON ERROR, THEN and ELSE clauses are all optional.

 

 

The ON ERROR clause is executed in the event of a fatal internal error. The error code returned by the STATUS() function will indicate the cause of the error. If this clause is omitted, the program will abort in the event of a fatal error.

 

The THEN clause is executed if the operation is successful. The STATUS() function will return zero.

 

The ELSE clause is executed in the event of a non-fatal error. If this clause is omitted, program execution continues after an error.

 

 

Example

 

PRINTER DISPLAY ON 1

 

This statement directs output from print unit 1 to the display.