Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Selection Screen Processing..

Former Member
0 Likes
788

Haii All..

I have done a program in which i have a selection-screen and a respective alv list, but the problem is that when i click f3 button on the alv list screen i should come back to the selection-screen and the previous input values shouldnt be gone so that i could continue with selection..

I have used leave to transaction sy-tcode, but the problem is that when i click the f3 button on the output screen, i come back to the selection-screen but the transaction is startting newly..and i am losing the previous values given in the selection-screen and when i use call selection-screen 1000 i am not able to come out of the selection-screen when i click f3 on the selection-screen.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
764

Assign the function code you want to the back button in PF-status.

There is no need of calling the screen again. The values will not be lost when you do like this

6 REPLIES 6
Read only

Former Member
0 Likes
765

Assign the function code you want to the back button in PF-status.

There is no need of calling the screen again. The values will not be lost when you do like this

Read only

0 Likes
764

See this code:

case sy-ucomm.

when 'BACK'.

call selection-screen 1000.

  • leave to transaction sy-tcode.

when 'CANCEL'.

leave program.

endcase.

when i click f3 it should come back again to the selection-screen, which is successfull for me and also the values are not lost..but the problem is that when i cilck f3 on the selection-screen m going to the output screen again rather than quit the program.

so i used leave to transaction sy-tcode, here m getting out of program but the values are lost in the selection-screen.

Hope its clear for u now.

Read only

0 Likes
764

Try this.



case sy-ucomm.
when 'BACK'.
  set screen 0.
  leave screen.

when 'CANCEL'.
  leave program.
endcase.

Regards,

RIch Heilman

Read only

0 Likes
764

Oh My God..Thanks a lot!

Its working now..

Read only

0 Likes
764

Yep, what is happening here is that you are now saying that there is no "Next screen" in the sequence, and you are leaving the current screen, which will always end the current screen and show the previous.

Regards,

Rich Heilman

Read only

0 Likes
764

Ok..thanks a lot for the answer..so is it that when we leave the current screen (for example output screen) and go back to the previous screen (input screen) the screen number is automatically assigned to the current screen.