‎2008 Apr 28 11:41 AM
HI EXPERTS,
I have defined a sample badi with single method 'dividing' with params number1, number2 , result ,status.status is for throwing exception .
Now my problem is in the following programme it is unable to create 'exit'.it is showing the message failed.
could u resolve it.
class cl_exithandler definition load.
data: exit type ref to ZIF_EX__BADITEST_DEFINE.
data: v_rnum type i,
v_stat type c.
selection-screen begin of block b1.
parameters:p_num1 type i,
p_num2 type i.
selection-screen end of block b1.
start-of-selection.
CALL METHOD CL_EXITHANDLER=>GET_INSTANCE
EXPORTING
EXIT_NAME = 'Z_BADITEST_DEFINE'
NULL_INSTANCE_ACCEPTED = seex_true
CHANGING
INSTANCE = exit
EXCEPTIONS
others = 1.
if not exit is initial.
call method exit->dividing
exporting
number1 = p_num1
number2 = p_num2
changing
result = v_rnum
status = v_stat .
else.
message 'failed' type 'I'.
endif.
if V_stat = space.
write : / 'result : ', v_rnum.
endif.
Regards,
Pavan.
‎2008 Apr 28 1:41 PM
Hi,
I think you have not implimented the defined badi.
For every badi defined there should be implimentation in se19.
Thanks,
NN.
Edited by: Nethaji babu on Apr 28, 2008 2:42 PM