Previous Topic
Table Of Contents
Parent Topic
Next Topic

The SWSEXDPL Function

Related Topics

Web Server API Function Index


May be used in Shadow/REXX
May be used from Other REXX Interpreters
High-level Language Interface available

The REXX-language SWSEXDPL built-in function is used to establish a CICS EXCI connect on behalf of the user.

Upon return from the call, the following Rexx variables are populated with data:

EXCI.STMTHDL The statement handle for the interface call.
EXCI.RETCODE The EXCI Return Code Area as mapped by the CICS Copybooks
EXCI.COMMAREA.1 The output COMMAREA from the CICS Transaction.
EXCI.DPLCODE The DPL Return Code Area as mapped by the CICS Copybooks

SWSEXDPL Syntax

The general form for a REXX-language invocation of SWSEXDPL is:


       rc = swsexdpl(Connection Type, ,
                     Connection Name, ,
                     CICS Transaction Name, ,
                     CICS Program Name, ,
                     CICS Transaction Input, ,
                     User Token, ,
                     Pipe Token)

Connection Type Specifies the type of connection

EXCI Use CICS EXCI interface

NEON Currently not supported.

Note: Required parameter.

Connection Name Logical name of the connection as specified on the "DEFINE CONNECTION" statement in the Shadow Initialization exec member (SWS_IN00)

Note: Required parameter.

CICS Transaction Name The Trans-ID of the mirror transaction with which the target program is to run under.

Note: Required parameter.

CICS Program Name The program to run and interact with via DPL requests.

Note: Required parameter.

CICS Transaction Input The input to the executing transaction passed through the COMMAREA. A COMMAREA will of 32,704 bytes will be allocated, the transaction input will be copied into this area and passed to the transaction.

Note: Required parameter.

User Token This is the token created as a result of the SWSEXINI API Call. Use the EXCI.USERTOKN Rexx variable name.

Note: Required parameter.

Pipe Token This is the token created as a result of the SWSEXCON API Call. Use the EXCI.PIPETOKN Rexx variable name.

Note: Required parameter.

 

SWSEXDPL Examples


 
     contype  = 'EXCI'          /*  Connection Type             */
     conname  = 'EWST'          /*  Connection Name from DEFINE */
     cicstran = 'EXCI'          /*  CICS Transaction Code       */
     cicspgm  = 'DFH$AXCS'      /*  CICS Program Name           */
     address swssend
 
     /*-----------------------------------------------------------*/
     /* Initialize the user                                       */
     /*-----------------------------------------------------------*/
         rc = swsexini(contype,conname)
 
     /*-----------------------------------------------------------*/
     /* Allocate a pipe                                           */
     /*-----------------------------------------------------------*/
         rc = swsexcon(contype,conname,EXCI.USERTOKN)
 
     /*-----------------------------------------------------------*/
     /* Issue DPL Request                                         */
     /*-----------------------------------------------------------*/
         parm  = '00000001'x||'FILEA   000001'
         rc = swsexdpl(contype,conname,cicstran,cicspgm, ,
                       parm,EXCI.USERTOKN,EXCI.PIPETOKN)
 
         pgmrc = substr(EXCI.COMMAREA.1,1,4)
         pgmrc = c2x(pgmrc)
 
         parm  = substr(EXCI.COMMAREA.1,5,14)
         parm  = '00000002'x||parm
 
         data  = substr(EXCI.COMMAREA.1,19,80)
 
     /*-----------------------------------------------------------*/
     /* Disconnect the pipe                                       */
     /*-----------------------------------------------------------*/
         rc = swsexdis(contype,conname,EXCI.USERTOKN,EXCI.PIPETOKN)
 
 

Top