SAP_CMACCP 

Use

The parameters needed in the called program to build the connection are passed as call parameters with both cpicslib and cpictlib. For this reason, the CPI-C interface needs to access the argument vector. By calling the function SAP_CMACCP, the address of the argument vector is passed to the CPI-C interface.

The header file cpic.h indicates the prototypes. SAP_CMACCP always returns the value CM_OK.

main (argv, argc)
..
SAP_CMACCP(argv);
..

Integration

Registering Programs at the SAP Gateway Without Changing the Source Code

If you specify relevant parameters when calling the target program, the program is registered at the gateway with the SAP_CMACCP call.

The SAP_CMACCP call analyzes the arguments passed. SAP_CMACCP then performs the calls SAP_CMREGTP and SAP_CMACCTP (see Functions for Registered CPI-C Programs).

This means you can use registered programs without makting changes to the source code. You must link such programs with the most recent library.

Transfer parameters:

TP

Transaction program name

GWHOST

Gateway platform

GWSERV

Gateway service

TIMEOUT

Time limit in seconds (optional) If you do not specify this parameter, no timeout occurs and the program waits until the next request.

Calling the program:

cpict2 TP=cpict2 GWHOST=hs0011 GWSERV=sapgw00