‎2009 Dec 05 8:27 AM
Hi All,
I have a required field in module pool programming. When i press Exit push button message displays "Fill in all required entry fields".
I want to exit from program without fill any field.
Is it possible. plz help me
‎2009 Dec 05 8:41 AM
Hi Sweta,
Go to your status of the Screen assign Function Type as E." Double Click on your PF Status for this.
Expand Function Keys and Double Click on EXIT word (Which you Placed Earlier) and Assign E as the Functional Type
in PAI of your program.
At Screen Level maintainOK_CODE in element List and also declare OK_CODE in TOP include.
MODULE exit AT EXIT-COMMAND.
in program.
MODULE exit .
CASE OK_CODE.
WHEN 'EXIT'.
LEAVE PROGRAM.
ENDCASE.
ENDMODULE.Cheerz
Ram
‎2009 Dec 05 2:57 PM
Hi,
Yes this is very well possible in SAP GUI. You have to define a Module in PAI processing block with the following notation:
MODULE <mod> AT EXIT-COMMAND.
Replace <mod> with you own module. Once you press the EXIT button this will be the module that will get executed without any other evaluation happening.
Have a look at this link for details:
http://help.sap.com/saphelp_nw04/helpdata/en/9f/dbaa9535c111d1829f0000e829fbfe/content.htm
Hope this will help.
Thanks,
Samantak.
‎2009 Dec 06 4:14 AM
You can achive the same , press F1 on MODULE <mod> AT EXIT-COMMAND.
You can also write LEAVE PROGRAM in the logic for function of the button using sy-ucomm.
‎2009 Dec 07 5:05 AM
Hi,
In the PF-Status, keep the Functional Type for the EXIT button as E.
And code for the same button in the module:-
PROCESS AFTER INPUT.
MODULE exit AT EXIT COMMAND.
MODULE exit.
CASE sy-ucomm.
WHEN 'EXIT'.
LEAVE PROGRAM. "<- to leave the transaction.
ENDCASE.
ENDMODULE.
Hope this helps you.
Regards,
Tarun
‎2009 Dec 07 6:48 AM