Pathway/iTS SCREEN COBOL Reference Manual (H06.10+, J06.03+)
Procedure Division
HP NonStop Pathway/iTS SCREEN COBOL Reference Manual—426750-003
6-90
RECONNECT MODEM Statement
If the connection to the Pathway/iTS terminal or to the intelligent device is over a
switched line, the RECONNECT MODEM statement breaks the connection with the
SCREEN COBOL program and causes the program to wait for another incoming call.
After the next incoming call completes connection to the terminal or device, the
SCREEN COBOL program resumes execution at the next program instruction.
If a RECONNECT MODEM statement is executed but the Pathway/iTS terminal or
device is not connected over a switched line, the program resumes immediately at the
next program instruction.
After a RECONNECT MODEM statement is executed, all terminal screen definitions
are lost. A DISPLAY BASE statement must precede the next screen operation.
RECONNECT MODEM lets a SCREEN COBOL program perform the following
operations for Pathway/iTS terminals or intelligent devices connected over switched
lines:
•
Disconnect the terminal or device at the end of a session (the caller logs off)
•
Recover from a modem error (an accidental disconnection), and wait for the next
terminal or device to call
The SCREEN COBOL program must be in a consistent state when accessed by an
incoming call. Initialize local variables and complete previous transactions before
executing RECONNECT MODEM.
The RECONNECT MODEM statement causes a full context checkpoint. If
Pathway/iTS is running under TMF and a terminal or intelligent device is in transaction
mode, this statement backs out the current transaction and suspends the terminal or
device so that it cannot be resumed. If an ABORT-TRANSACTION statement
precedes the RECONNECT MODEM statement, Pathway/iTS attempts to resume
communication with the terminal or device after a modem error.
The following example illustrates the RECONNECT MODEM statement:
START-PROGRAM.
CALL SEARCH-PROGRAM ON ERROR GO TO VERIFY-RECONNECT.
RECONNECT MODEM.
GO TO START-PROGRAM.
VERIFY-RECONNECT.
IF TERMINATION-STATUS IS = 18 AND
TERMINATION-SUBSTATUS IS = 140
* This is a modem error - return to a consistent state
* and wait for the next terminal caller.
DELAY 10
RECONNECT MODEM
GO TO START-PROGRAM.
* Processes other error conditions.
DISPLAY BASE SEARCH-SCREEN.
or










