C PARM EPNTNM
C PARM 'EXMP1'EPTFMT 8
C PARM EPGMNB
C PARM QUSCCB
C PARM QUSBN
Cᑍ
Cᑍ If an exception occurs, the API returns the exception in the
Cᑍ error code parameter. The bytes available field is set to
Cᑍ zero if no exception occurs and greater than zero if an
Cᑍ exception does occur.
Cᑍ
C QUSBNC IFGT
C OPEN QPRINT
C EXCPTERREPT
C EXSR DONE
C ENDIF
Cᑍ
Cᑍ If the call to retrieve exit point information is successful,
Cᑍ check to see if there are any exit programs to call.
Cᑍ
C 36 SUBSTRCV:1 QUSCG
C QUSCGG IFGT
C 1 ADD QUSCGF X
C 21 SUBSTRCV:X QUSCF
C QUSCFF IFGT
Cᑍ
Cᑍ There are some exit programs to call. Blank out the continuation
Cᑍ handle to let the API know that this is a first attempt at the
Cᑍ retrieve operation.
Cᑍ
C MOVE ᑍBLANKS CONTHD
Cᑍ
Cᑍ Call the exit programs
Cᑍ
C EXSR CUSREI
Cᑍ
Cᑍ If the continuation handle field in the receiver variable is
Cᑍ not set to blanks, the API has more information to return than
Cᑍ what could fit in the receiver variable. Call the API for
Cᑍ more exit programs to call.
Cᑍ
C QUSCGD DOWNEᑍBLANKS
C MOVELQUSCGD CONTHD
C EXSR CUSREI
C ENDDO
C ENDIF
C ENDIF
C EXSR DONE
Cᑍ
Cᑍ End of MAINLINE
Cᑍ
Cᑍ Process exit programs in receiver variable
Cᑍ
C CUSREI BEGSR
Cᑍ
Cᑍ Call the API to retrieve the exit program information
Cᑍ
C CALL 'QUSRTVEI'
Appendix B. Original Examples in Additional Languages B-73