‎2006 Jun 28 9:51 AM
Hi all,
Apparently, I wish to pass 2 parameters from sapscript to called program, and trigger the subroutine from the program to manipulate some data. Below is my coding in my sapscript:
PERFORM GET_PO_MAT_TEXT IN PROGRAM ZMMSCC_PO_OUTPUT
USING &EKPO-EBELN& &EKPO-EBELP&
CHANGING &PO_MAT_TXT&
ENDPERFORM
<u>Called Program:</u>
READ TABLE in_param WITH KEY 'EKPO-EBELN'.
IF sy-subrc = 0.
lebeln = in_param-value.
endif.
READ TABLE in_param WITH KEY 'EKPO-EBELP'.
IF sy-subrc = 0.
lebelp = in_param-value.
endif.
Based on the coding above, the program reads incoming parameters with key EKKO-EBELN and EKKO-EBELP, however, I just can grab the value from parameter EKKO-EBELN only, not both of value from EKKO-EBELN and EKKO-EBELP.
Can somebody guide me on how to pass two parameters from a sapscript to a subroutine program?
Any advise will be much appreciated.
Thanks.
Patrick
‎2006 Jun 28 9:55 AM
Hi Patrick
You have to add the USING statement before each parameter:
PERFORM .....
USING &EKKO-EBELN&
USING &EKKO-EBELP&
CHANIGN ...
Regards,
John.