2007 Jun 26 8:24 AM
h experts,
i have developed a module pool report in which in the selection screen i have four fields which are mandatory ,when i execute the program without entering in the selection screen it do not allow to come out of the module pool screen ...what i want that without entering any input in the selection screen if i press exit button push button it will allow to come out of the screen for this what sud i do plz help me....
2007 Jun 26 8:28 AM
Hi,
U need to write the AT EXIT-COMMAND command.
In PAI
MODULE EXIT_XXXX AT EXIT-COMMAND.
Now u have write the code as.
IF SY-UCOMM = 'EXIT'.
LEAVE TO SCREEN 0.
ENDIF.
Now go to EXIT button on the toolbar.U have to make As type E.
Regards,
Nagaraj
Hi,
U need to write the AT EXIT-COMMAND command.
In PAI
MODULE EXIT_XXXX AT EXIT-COMMAND.
Now u have write the code as.
IF SY-UCOMM = 'EXIT'.
LEAVE TO SCREEN 0.
ENDIF.
Now go to EXIT button on the toolbar.U have to make As type E.
Regards,
Nagaraj
2007 Jun 26 8:26 AM
HI,
In your PAI add a module as follows
MODULE EXIT_XXXX AT EXIT-COMMAND.
MODULE EXIT_XXXX.
if ok_code = 'EXIT'.
LEAVE PROGRAM.
ENDIF.
ENDMODULE.
EXIT button on the toolbar has FUNCTION TYPE 'E' only function type's can enter a module with addition AT EXIT-COMMAND.
Regards,
Sesh
.
2007 Jun 26 8:28 AM
Hi,
U need to write the AT EXIT-COMMAND command.
In PAI
MODULE EXIT_XXXX AT EXIT-COMMAND.
Now u have write the code as.
IF SY-UCOMM = 'EXIT'.
LEAVE TO SCREEN 0.
ENDIF.
Now go to EXIT button on the toolbar.U have to make As type E.
Regards,
Nagaraj
2007 Jun 26 8:29 AM
hi,
try this code,
module exit_prg at exit-command.
module exit_prg input.
if sy-ucomm = 'CANCEL'.
leave program.
endif.
endmodule. " for this cancel you should give <b>e</b> function type at pf-status.
reward points if useful,
regards,
seshu.
2007 Jun 26 8:31 AM
In the PAI of the screen you have to code a module with exit command as first module.
syntax is 'MODULE MMMMM AT EXIT-COMMAND'
In this module the code is there to leave screen for ok codes cancel, exit etc.
This code will be executed prior to checking mandatory fields on the screen.
2007 Jun 26 8:31 AM
Hi
keep a button called <b>EXIT</b> on the screen
Make the function type of that field as <b>E</b>
in Flow logic write
PROCESS AFTER INPUT.
Forced Exit from the transaction from screen
MODULE exit AT EXIT-COMMAND.
double click on exit module and
then in PAI write
&----
*
*& Module exit INPUT
&----
Exit from the Transaction
----
MODULE exit INPUT.
CASE okcode.
WHEN 'EXIT' OR 'CANCEL'.
CLEAR okcode.
LEAVE PROGRAM.
ENDCASE.
ENDMODULE. " exit INPUT
<b>Reward points for useful Answers</b>
Regards
Anji
2007 Jun 26 8:37 AM
HI.
your question:when i execute the program without entering in the selection screen it do not allow to come out of the module pool screen
if filed1 is not initial.
call screen NO
else .
message 'Enter all mandotry fields' type 'E'.
end if
your question:what i want that without entering any input in the selection screen if i press exit button push button it will allow to come out of the screen
In PAI
MODULE EXIT_XXXX AT EXIT-COMMAND.
Now u have write the code as.
IF SY-UCOMM = 'EXIT'.
if field1<manditory field> is initial.
LEAVE TO SCREEN 0.
else.
message 'You may loos your inputs' type 'E'
ENDIF.
reward all helpfull answers.
regrds.
Jay
| User | Count |
|---|---|
| 5 | |
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |