11-12-2007 11:28 PM
Hi,
In the sales order user exit I want to introduce CALL_BAPI = X .
How should I know in the exit the call to this process is from BAPI.
In online transaction I get sy-tcode = VA02 , VA42 .
But when it is BAPI call , how should I track this, is there any system field? .
Regards
Prashant.
11-12-2007 11:36 PM
I don't have any idea about the system field but you can do it like this:
Before calling the BAPI set some memory in ABAP memory.
Like:
data: l_flag.
L_FLAG = 'X'.
EXPORT L_FLAG to memory id 'ZBAPI'.
In your user exit import this data from memory.
data: l_flag.
IMPORT L_FLAG from memory id 'ZBAPI'.
if l_flag = 'X'.
** called from BAPI.
endif.
free memory id 'ZBAPI'.
Regards,
Naimesh Patel