2014 Nov 17 3:45 PM
Hi,
I have implemented one badi /POSDW/ACTION. But, when I am trying to call the BADI Implementation inside the program, it is giving the below error.
CLASS XX does not contain an interface.
Can you give some inputs pls.
Code:
DATA: lw_handler TYPE REF TO /POSDW/ACTION.
****
GET BADI LW_HANDLER
FILTERS
/POSDW/ACTIONFILTER = '0004'.
CALL BADI LW_HANDLER->/POSDW/IF_EX_ACTION~CALL
EXPORTING
FLT_VAL = '4'
I_TRANSACTION = lwa_tran
I_TASK = lwa_task
I_RULE = lwa_rule
I_CONDITIONRESULT = ''
IT_RULERESULT = lt_result.
BR/ Josh
2014 Nov 17 6:39 PM
Hi Josh
could you please try this approach
DATA bd TYPE REF TO badi_name.
GET BADI bd
FILTERS
lang = 'D'.
CALL BADI bd-> method
exporting x= 10.
by seeing the way of calling in your program
CALL BADI LW_HANDLER->/POSDW/IF_EX_ACTION~CALL
you had included an interface too over here. Request you to please check that and see whether its really required or not while calling methods in that BADI.
Thanks
2014 Nov 17 6:39 PM
Hi Josh
could you please try this approach
DATA bd TYPE REF TO badi_name.
GET BADI bd
FILTERS
lang = 'D'.
CALL BADI bd-> method
exporting x= 10.
by seeing the way of calling in your program
CALL BADI LW_HANDLER->/POSDW/IF_EX_ACTION~CALL
you had included an interface too over here. Request you to please check that and see whether its really required or not while calling methods in that BADI.
Thanks
2014 Nov 17 7:59 PM
Thankyou Kishore.
Issue was not just that. Since the new BADI implemented was called inside another badi implementation, there was a conflict occurring while the method is called.
I have created a spot inside and then called the badi.
New Code.
GET BADI LW_HANDLE FILTERS /POSDW/ACTIONFILTER = '0005'.
CALL BADI LW_HANDLE->CALL
EXPORTING
FLT_VAL = '0005'
I_TRANSACTION = lwa_tran
I_TASK = lwa_task
I_RULE = lwa_rule
I_CONDITIONRESULT = ''
IT_RULERESULT = lt_result.
This worked fine.