‎2008 Aug 28 2:24 PM
Hi experts,
In screen painter I use AT EXIT-COMMAND to exit current screen as the following code. But it doesn't exit the screen if ok_code = 'create' while other ok_code work well. Can anyone tell me that's why?
Thanks!
module exit.
if SY-UCOMM = 'EXIT' or SY-UCOMM = 'BACK'.
LEAVE PROGRAM.
elseif SY-UCOMM = 'CLEAR' or SY-UCOMM = 'CREATE'.
CALL SCREEN 100.
endmodule.
‎2008 Aug 28 2:27 PM
‎2008 Aug 28 2:27 PM
‎2008 Aug 28 2:28 PM
write this statement in PAI
and check weather sy-ucomm capturing the key r not
MODULE EXIT.
IF sy-ucomm = 'LEAV'
SET SCREEN 0.
LEAVE SCREEN.
ENDIF.
ENDMODULE.
Regards
Anbu B
‎2008 Aug 28 2:28 PM
Did you Set the Function code as Type E then only it will tigger.
check this program,,.
DEMO_DYNPRO_AT_EXIT_COMMAND
‎2008 Aug 28 2:34 PM
Hi,
module exit.
if SY-UCOMM = 'EXIT' or SY-UCOMM = 'BACK'.
LEAVE LIST-PROSSESING." TO COME BACK
elseif SY-UCOMM = 'CLEAR' or SY-UCOMM = 'CREATE'.
REFRESH ITAB." FOR INTRNAL TABLE
CLEAR WA." FOR WORKAREA
CALL SCREEN 100.
endmodule.
NOW USE THIS .
Thanks & Regards,
D Tarun Kumar.
‎2008 Aug 28 2:59 PM