‎2009 Nov 25 8:02 AM
Hi Guru's,
I am calling a zprogram using SUBMIT and Return. I am skipping the selection screen.
My problem is when i press back button on the called program screen it brings me back to selection screen of the called program . I want to cm back to the screen from where i have called the zprogram.
How can i achieve that?
Regards,
Nikhil
‎2009 Nov 25 8:14 AM
You have to handle the logic of back button.
In logic of back button you can write :
Leave to screen or Leave Program.
Press F1 on leave.
‎2009 Nov 25 8:07 AM
Try using LEAVE PROGRAM statement when you press BACK .
Regards
Marcin
‎2009 Nov 25 8:13 AM
SUBMIT PROGNAME WITH dbname EQ v_fln1
EXPORTING LIST TO MEMORY
AND RETURN.
‎2009 Nov 25 8:14 AM
You have to handle the logic of back button.
In logic of back button you can write :
Leave to screen or Leave Program.
Press F1 on leave.
‎2009 Nov 25 8:37 AM
Hi,
I don't seem to get this issue. Sorry if I am getting your question wrong.
Did you use this USING SELECTION-SCREEN?
‎2009 Nov 25 8:54 AM
‎2009 Nov 25 8:58 AM
Yes i have tried everything thats mentioned above but none of this works.
‎2009 Nov 25 9:12 AM
Hi,
What is the code written after the SUBMIT Stmt??
Generally, the SUBMIT and RETURN will call the program and on BACK of the o/p of called prog, it continues to the next statemnt after SUBMIT.
Thanks,
Teja.
‎2009 Nov 25 9:18 AM
Hi teja,
My statement is as follows.
SUBMIT ZREPORT WITH SELECTION-TABLE ITAB AND RETURN.
So the report is displayed in ALV, when i press the back button on the ALV list it displays the selection screen.
I want to come back to the next statement after SUBMIT and the selection screen should be skipped when i press the back button.
Regards,
Nikhil
‎2009 Nov 25 9:31 AM
‎2009 Nov 25 9:40 AM
HI abapdev,
There's a selection associated with ZREPORT which is getting skipped because i am using my submit like that. Once i click back on the ZREPORT i want to skip the selection screen of ZREPORT.
I am not concerned about the ZMAIN output.
Regards,
Nikhil
‎2009 Nov 25 9:44 AM
Hi,
Please see the below code which i did..
calling program
TABLES : mara.
PARAMETERS: p_matnr LIKE mara-matnr.
DATA : itab LIKE mara OCCURS 0 WITH HEADER LINE.
SELECT * FROM mara INTO TABLE itab UP TO 100 ROWS.
SUBMIT zytr3 AND RETURN.
LOOP AT itab.
WRITE :/ itab-matnr.
ENDLOOP.
called program
TABLES : mara.
PARAMETERS: p_matnr LIKE mara-matnr.
DATA : itab LIKE mara OCCURS 0 WITH HEADER LINE.
SELECT * FROM mara INTO TABLE itab UP TO 100 ROWS.
LOOP AT itab.
WRITE :/ itab-matnr.
ENDLOOP.
first i will get the output of called program and then calling program and then selection screen of calling program.
Regards,
nagaraj
‎2009 Nov 25 9:50 AM
Your code is perfect.
But my problem is the called program is a dialog program and on the back button of that a code is already written. So i have to skip that code and have to come back to my calling screen.
Regards,
Nikhil.
‎2009 Nov 25 9:57 AM
Save Our Environment. Save Yourself.
Hi Nikhil,
I afraid... this is not possible.
The code is already existing in the called program and if you don't want that it means you have to change that called program.
And this will definitely have impact on the existing ZREPORT (ZREPORT might be run separately also).
- I'm not an environmentalist. I'm an Earth warrior.
‎2009 Nov 25 10:12 AM
if the first program has an transaction.
try
leave to TRANSACTION 'ZRR'.
Remove return from submit statement
‎2009 Nov 25 10:16 AM
Hello KSD,
Where does the OP write LEAVE TO TRANSACTION after SUBMIT AND RETURN ? Please enlighten us.
BR,
Suhas
‎2009 Nov 25 10:26 AM
‎2009 Nov 25 10:29 AM
So he has to change the code of the "called" program Which is easy if this is a custom code
I doubt the OP has to live with this functionality else go for a CALL TRANSACTION(if it is a standard code), whatsay guys ??
BR,
Suhas
‎2009 Nov 25 11:00 AM
He also passes a selection set.
call transaction also will do.
But if its a standard code ... its hard.
‎2009 Nov 25 11:02 AM
‎2009 Nov 25 11:42 AM