2014 May 15 2:27 PM
Hi Experts,
I am facing issue while doing SUBMIT REPORT statement.
Below are the details for the Issue:
1. We want to execute another report ZTEST2 from one report , so we have written code in report ZTEST1 as below:
SUBMIT ZTEST2 AND RETURN.
2. It goes to ZTEST2 successfully but when we execute ZTEST2 and click on BACK buttton , it directly goes to ZTEST1 selection screen.
Instead we want to go ZTEST2 program's selection screen. As this back button is standard ALV button is there any way we can handle this without creating new PF-STATUS.
Regards,
Sanjana
2014 May 15 3:15 PM
Exclude the 'AND RETURN' statement. Use ' SUBMIT ZTEST2 VIA SELECTION-SCREEN'.
Regards,
Satya
Hi Experts,
I am facing issue while doing SUBMIT REPORT statement.
Below are the details for the Issue:
1. We want to execute another report ZTEST2 from one report , so we have written code in report ZTEST1 as below:
SUBMIT ZTEST2 AND RETURN.
2. It goes to ZTEST2 successfully but when we execute ZTEST2 and click on BACK buttton , it directly goes to ZTEST1 selection screen.
Instead we want to go ZTEST2 program's selection screen. As this back button is standard ALV button is there any way we can handle this without creating new PF-STATUS.
Regards,
Sanjana
2014 May 15 2:42 PM
Hi Sanjana,
I don't think you can. My suggestion is to use a parameter ID, like this:
counter = 0.
set parameter id 'counter'
do.
SUBMIT ZTEST2 AND RETURN.
get parameter id 'counter'
if counter >= 2.
exit.
enddo.
so you'll resubmit every time your counter < 2
And inside ZTEST2 at:
initialization.
add 1 to counter.
set parameter id 'counter'
start-of-selection
counter = 0.
set parameter id 'counter'
so if you execute you reset the counter and your program will resubmit
in ztest 2 after executing you'll press back and resubmit will present the selection screen. If you press back now, counter is 2 and program will leave the DO instruction.
regards,
Edgar
2014 May 15 2:56 PM
Hi Edgar,
We do not want to make any changes in ZTEST2 , is it possible to do anything in calling program only.
Regards,
Sanjana
2014 May 15 3:10 PM
That's very limiting.
It depends, there are some things you can do if you ztest2 does something that is traceable.
Without any more info I suggest to check time-lapse between submit calls. If it's inferior to 2 seconds I'd suppose user want's to leave.
mind you the syntax is wrong:
do.
g_initial = get time.
SUBMIT ZTEST2 AND RETURN.
g_final = get time.
if g_final - g_initial <= 2.
exit.
endif.
enddo.
For the user is in most cases transparent, only if he remains a lot of time in selection screen he'll remain there.
regards,
Edgar
2014 May 15 3:15 PM
Exclude the 'AND RETURN' statement. Use ' SUBMIT ZTEST2 VIA SELECTION-SCREEN'.
Regards,
Satya
2014 May 15 3:19 PM
Well, I agree. I was assuming there's some logic yet for processing in first report :). Maybe there isn't.
2014 May 15 3:24 PM
2014 May 15 3:24 PM
hi,
Use SUBMIT <program name> via selection screen....this will take u to selection screen of the prog first
and when u press back it will return back again to the called selection screen.
regards,
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |