ATMI COBOL Function Reference
|
|
TPSETCTXT() - sets a context identifier for the current application association
01TPCONTEXTDEF-REC.
COPY TPCONTEXTDEF.
01TPSTATUS-REC.
COPY TPSTATUS.
CALL "TPSETCTXT" USING TPCONTEXTDEF-REC TPSTATUS-REC.
TPSETCTXT() defines the context in which the current program operates. (Multithreaded COBOL applications are not currently supported.) Subsequent BEA Tuxedo calls reference the application indicated by CONTEXT in TPCONTEXTDEF-REC. The value of CONTEXT in TPCONTEXTDEF-REC should have been provided by a previous call to TPGETCTXT(). If the value of CONTEXT is TPNULLCONTEXT, then the program is disassociated from any BEA Tuxedo context. TPINVALIDCONTEXT is not a valid input value for CONTEXT in TPCONTEXTDEF-REC.
Upon successful completion, TPSETCTXT() sets TP-STATUS to [TPOK].
Upon failure, TPSETCTXT() leaves the calling process in its original context and sets TP-STATUS to indicate the error condition.
Upon failure, TPSETCTXT() sets TP-STATUS to one of the following values:
TPSETCTXT() has been called in an improper context. For example, it has been called in a process that has not called TPINITIALIZE() or that has called TPINITIALIZE() without specifying the TP-MULTI-CONTEXTS setting.
A BEA Tuxedo system error has occurred. The exact nature of the error has been written to a log file.
Introduction to the COBOL Application-Transaction Monitor Interface, TPGETCTXT(3cbl)
|
|
|