Hi,
I have executed a Process chain using the FM RSPC_API_CHAIN_START:
CALL FUNCTION 'RSPC_API_CHAIN_START'
EXPORTING
i_chain = 'ZPC_TEST'
I_T_VARIABLES =
i_synchronous = 'X'
I_SIMULATE =
I_NOPLAN =
I_DONT_WAIT = 'X'
I_POLL =
IMPORTING
e_logid = v_logid
EXCEPTIONS
failed = 1
OTHERS = 2.
I need know when this process chain have finished in order to populate the log by screen. I was using other function RSPC_API_CHAIN_GET_STATUS into a loop in order to give the status. This FM return A = Active, G = Green, R = Red OR X = Aborted.
WHILE v_status ne 'G' or v_status NE 'R'.
CALL FUNCTION 'RSPC_API_CHAIN_GET_STATUS'
EXPORTING
i_chain = 'ZPC_TEST'
i_logid = v_logid
I_DONT_UPDATE =
I_DONT_POLL =
IMPORTING
e_status = v_status.
ENDWHILE.
the variable should be updated with the current status of the execution but if i execute this code the execution not finish (infinite loop).
Please, how could I know the correct status of the PC?
Thx in advance!