Ansicht
Dokumentation

04596 - Calling a CLP program with one parameter from an ABAP program

04596 - Calling a CLP program with one parameter from an ABAP program

SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3up   BAL_S_LOG - Application Log: Log header data  
This documentation is copyright by SAP AG.
SAP E-Book

Calling a CLP program with one parameter from an ABAP program

--- In SAP on System iZy..., "Ariel Stanietski" <arielZc...> wrote:
>
> >
> >
> > Hello all,
> > It works nice from SM49.
> > Can somebody send me an example of
> > the ABAP relevant lines ?
> > Thanks in advance,
> > Ariel Stanietski
> > Carmel-Olefins
> > Haifa, Israel.
> >
> >

Ariel,

I use the function Module SXPG_CALL_SYSTEM:


commandname like sxpgcolist-name value 'YOUR_SM49_COMMAND'
parm1 like sxpgcolist-parameters.

call function 'SXPG_CALL_SYSTEM'
exporting
commandname = YOUR_SM49_COMMAND
parameters = parmALL


This has worked quite well with one exception.
I had to concatenate single quotes around the parm
when sending it to the OS.

Example --
data: tick value ''''.
concatenate tick parm1 tick into parmALL.

Pass ParmALL to CL program so you get 'Your parameter' in single
quotes.

I use this because some parameters I pass have special
characters or spaces.

I am not a programmer, so there may be a better way
but it's working good for me.


Regards,

Philip Stracener
CV Industries



Durban Tours - Südafrika Safari

TXBHW - Original Tax Base Amount in Local Currency   BAL Application Log Documentation  
This documentation is copyright by SAP AG.

Length: 1673 Date: 20240621 Time: 024730     sap01-206 ( 3 ms )