‎2007 May 17 6:06 AM
Hi Friends,
I am using an Update Function Module in my program.The Program also has various other logics implemented in it. The Update Function Module gets triggered only when it finds COMMIT WORK statement. Now, I want that when the FM gets triggered and inside it, sy-subrc <> 0 at any stage, it should exit the complete processing and come to my main screen.
I tried to use Exit, STOP commands in the FM, but they only make the processing to exit from the FM.
Please suggest what shud I do.
Helpful suggestions will be surely rewarded.
Thanks in advance.
Regards,
Himanshu
‎2007 May 17 6:13 AM
Hi Himanshu,
Once you come out the Update FM using EXIT or STOP then check for the sy-subrc in calling program and if it is not 0 then you can once again write the exit commands to the main program screen
Regards,
Atish
‎2007 May 17 6:13 AM
Hi Himanshu,
Once you come out the Update FM using EXIT or STOP then check for the sy-subrc in calling program and if it is not 0 then you can once again write the exit commands to the main program screen
Regards,
Atish
‎2007 May 17 6:18 AM
in ur calling program just below the FM call write followiing statement -
Check sy-subrc EQ '0'.
‎2007 May 17 6:53 AM
hi hemansu,
after coming out from function module check value of sy-subrc
and
if sy-subrc ne 0
exit. or leave to screen 0 [module pool progarm] or stop.
endif.
if helpful reward some points.
with regards,
suresh babu aluri.