SET ADDRESS OF QUS-EXTI2 TO BASE-POINTER.
ᑍ
IF NUMBER-POINTS-RETURNED OF QUS-EXTI1 >
SET ADDRESS OF QUS-EXTI1-ENTRY TO
ADDRESS OF RCVVAR((OFFSET-EXIT-POINT-ENTRY OF
QUS-EXTI1 + 1):)
ELSE STOP RUN.
ᑍ
IF NUMBER-EXIT-PROGRAMS OF QUS-EXTI1-ENTRY >
ᑍ
ᑍ There are some exit programs to call. Blank out the continuation
ᑍ handle to let the API know that this is a first attempt at the
ᑍ retrieve operation.
ᑍ
MOVE SPACES TO CONTINUATION-HDL,
ᑍ
ᑍ Call the exit programs
ᑍ
PERFORM CALL-EXIT-PROGRAMS,
ᑍ
ᑍ If the continuation handle field in the receiver variable is
ᑍ not set to blanks, the API has more information to return than
ᑍ what could fit in the receiver variable. Call the API for
ᑍ more exit programs to call.
ᑍ
PERFORM UNTIL CONTINUE-HANDLE OF QUS-EXTI2 = SPACES
MOVE CONTINUE-HANDLE OF QUS-EXTI2
TO CONTINUATION-HDL,
PERFORM CALL-EXIT-PROGRAMS,
END-PERFORM.
ᑍ
STOP RUN.
ᑍ
ᑍ End of MAINLINE
ᑍ
ᑍ
ᑍ Process exit programs in receiver variable
ᑍ
CALL-EXIT-PROGRAMS.
ᑍ
ᑍ Call the API to retrieve the exit program information
ᑍ
CALL PROCEDURE "QusRetrieveExitInformation" USING
CONTINUATION-HDL, RCVVAR,
BY CONTENT LENGTH OF RCVVAR,
FORMAT-NAME-1,
EXIT-POINT-NAME OF MISC,
FORMAT-NAME-2, EXIT-PGM-NBR,
NBR-OF-SELECT-CRITERIA, QUS-EC.
ᑍ
ᑍ If an exception occurs, the API returns the exception in the
ᑍ error code parameter. The bytes available field is set to
ᑍ zero if no exception occurs and greater than zero if an
ᑍ exception does occur.
ᑍ
IF BYTES-AVAILABLE OF QUS-EC >
OPEN OUTPUT LISTING,
MOVE EXCEPTION-ID OF QUS-EC
B-70 System API Programming V4R1