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

problem in selection screen

Former Member
0 Likes
497

Hi,

I have created two screens and called one after another with some usercommands at standard selection screen.When I press enter or execute at the third screen it comes back to the 1st screen(select screen-1000).But I do not want this.Please help.Following is my code.

SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.

PARAMETERS: a TYPE xxxx ,

b TYPE xxxx,

c TYPE xxxx .

SELECTION-SCREEN END OF BLOCK b1.

*Selection screen for 2nd screen

SELECTION-SCREEN: BEGIN OF SCREEN 2000 TITLE text-017 .

SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE TEXT-016.

PARAMETERS: pdir type STRING OBLIGATORY DEFAULT TEXT-020.

SELECTION-SCREEN PUSHBUTTON 79(10) but1 user-command CLI1.

SELECTION-SCREEN END OF BLOCK b2.

SELECTION-SCREEN:END OF SCREEN 2000.

SELECTION-SCREEN: BEGIN OF SCREEN 3000 TITLE text-017 .

SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE TEXT-018.

PARAMETERS: pdir1 type STRING OBLIGATORY DEFAULT TEXT-020.

SELECTION-SCREEN PUSHBUTTON 79(10) but2 user-command CLI2.

SELECTION-SCREEN END OF BLOCK b3.

SELECTION-SCREEN:END OF SCREEN 3000.

AT SELECTION-SCREEN .

CASE sy-dynnr.

WHEN 1000.

CASE sy-ucomm.

WHEN c_create.

PERFORM create.

WHEN c_push.

PERFORM show.

WHEN c_execute.

CALL SELECTION-SCREEN 2000.

WHEN c_back OR c_end OR c_canc.

LEAVE PROGRAM.

ENDCASE.

WHEN 2000.

CASE sy-ucomm.

WHEN 'CLI1'

PERFORM load.

WHEN c_execute.

PERFORM update

CALL SELECTION-SCREEN 3000.

ENDCASE.

WHEN 3000.

CASE sy-ucomm.

WHEN execute.

PERFORM download.

ENDCASE.

ENDCASE.

3 REPLIES 3
Read only

Sandeep_Panghal
Product and Topic Expert
Product and Topic Expert
0 Likes
474

If you want to stay in screen 3000 only then you can use set screen 3000.

Read only

Former Member
0 Likes
474

what do you want if enter or execute is pressed at 3000 screen.

Please elaborate.

To debug just comment CASE statement at 3000 screen.

regards,

Sunny

Read only

former_member212005
Active Contributor
0 Likes
474

Check your subroutine PERFORM download......is there any exit statement in it..

Your code works fine for me...without subroutines...