‎2008 May 08 11:55 AM
Hello Friends,
Its very very urgent..i am having 2 screen 100 and 500 of which 500 is my first screen and 100 is second screen. After giving input in 500 screen i am going to 100 screen in which 10 fields are there of which all are mandatory.
If my end user is entering 3 or any number if he dont want to continue then he wants to come back to 500 screen i.e first screen.
In screen painter for ALL THE fields in have given as REQUIRED so tht they will be mandatory. But in menu when i am clicking back it is showing a message like fill in all the required fields. Please can anyone give me solution for this.
‎2008 May 08 11:59 AM
Hi ,
A simpler solution would be to not make the fields mandatory , only check if they are entered when you do processing based on the data entred in the screen.
in case you want to retain the fields as mandatory you can try setting the Back button as an exit command and in the PAI write the code to go back to the previous screen.
Regards
Arun
‎2008 May 08 12:10 PM
Hi Sir,
Thks for responding but i didnt got you can it be more precise. sir its very very urgent.
‎2008 May 08 12:25 PM
Hi ,
I feel option one is self explanitory , just make the fields not mandatory and check if it has values when you are actually doing some proceessing with the data .,
For the second option
For every screen you will be using a menu and setting it using SET PF-STATUS , for the menu in second screen set the BACK button function type as EXIT and in the PAI of the screen add a new module some thing like
MODULE EXIT AT EXIT-COMMAND.
in the EXIT module you can write the command
SET SCREEN 500 .
leave screen.
Feel free to revert back in case you have any further queries , assign points if reply is helpful.
Regards
Arun
‎2008 May 08 12:32 PM
Hi Arun thks for responding, here even though i tried with set screen 500 with exit command then also it is not working it diractly passing out of program but i want to go back to 500 previous screen...
‎2008 May 08 1:15 PM
Hi ,
Here is the what you need to do.
1. Back Button in screen 500 normal Application
2. Back buttoin the screen 100 , set this as EXIT and in the PAI of the screen 100 create the new module for exit command.
In the module write the code SET SCREEN 500.
Leave Screen.
Please revert back with how your application works now
Regards,
Arun
‎2008 May 08 1:18 PM
First have a read of
[Calling Modules Unconditionally|http://help.sap.com/saphelp_nw70/helpdata/en/9f/dbaa9535c111d1829f0000e829fbfe/content.htm]
and then check your code goes something like
*" from PAI in first screen, say 1100
call screen 1200.
break-point. "to confirm your exit command gets back here
and in the "at exit-command" module of your second screen (1200) which will be triggered when you select a user-command which is flagged with the "E" function code
*" in PAI of second screen in at exit-command
break-point. "to check you reach this in the at exit-command
leave to screen 0. "return to caller
If you aren't hitting the break points then your PF-STATUS may not be set quite right, with the "E" function code on your "EXIT" option,
Jonathan