Pathway/iTS TCP and Terminal Programming Guide

Compaq NonStop™ Pathway/iTS TCP and Terminal Programming Guide426751-001
10-1
10
Handling Errors
This section discusses the following topics related to error handling in SCREEN
COBOL requesters:
Terminal Errors
Handling of SEND statement errors
The Pathway to TUXEDO translation server can also return error messages to
requesters. Information about these errors is given in the NonStop™ TUXEDO System
Pathway Translation Servers Manual.
Terminal Errors
During terminal startup, the TCP retries, aborts, or suspends a terminal depending on the
terminal error that had occured.
If an error occurs after the application is running on the terminal, the TCP invokes the
user recovery routines in the SCREEN COBOL program whenever possible. The USE
FOR SCREEN RECOVERY clause is invoked when there are terminal or
communications errors, processor failures, or terminal suspension. Typically, the
SCREEN COBOL program displays an advisory text message on the screen, and the
user must then take corrective action.
If no user error recovery is provided in the SCREEN COBOL program, then the TCP
takes its own action on terminal errors. The USE FOR TERMINAL-ERRORS clause is
invoked when there is an irrecoverable error due to a terminal error or communications
device error. This clause cannot be used for programs that communicate with intelligent
devices. If the USE FOR TERMINAL-ERRORS clause is present, suspension is
overridden (in most cases), so the USE FOR SCREEN RECOVERY clause would not
be invoked.
Error 140 Suspends the terminal immediately, unless user exception-
handling code is available in the the USE FOR TERMINAL-
ERRORS clause or in an ON ERROR clause within a CALL
statement, and invokes SCREEN COBOL exception-handling
code if available.
Error 191 Initiates a DISPLAY RECOVERY operation, and invokes any
code in the USE FOR SCREEN RECOVERY clause.
Errors 300 to 511 Suspends the program immediately, unless user exception code is
available in the USE FOR TERMINAL-ERRORS clause or in an
ON ERROR clause within a CALL statement, and invokes
SCREEN COBOL exception-handling code if available.
Other Errors If the retries do not succeed, then the TCP suspends the terminal,
unless user exception-handling code is available in the USE FOR
TERMINAL ERRORS clause or in an ON ERROR clause within
a CALL statement, and invokes SCREEN COBOL exception-
handling code, if available.