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

Multiple Selection-Screens

Former Member
0 Likes
7,496

Hi

I have a scenario where i need to have three selection-screens

.

When we execute the prg the first selection-screen should be displayed with 2 radio buttons

When 1st radiobutton is selected, it has to take us to 2nd selection-screen.

When 2nd radiobutton is selected, it has to take us to 3rd selection-screen.

I tried some code using loop at screen. but it dint work.

Can anyone suggest any solution.

Thanks in Advance,

Regards

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
3,603

Try this code:

REPORT ZDYNAMIC_PROGRAM.

PARAMETERS: rb1 RADIOBUTTON GROUP ab MODIF ID bl2,

rb2 RADIOBUTTON GROUP ab MODIF ID bl2.

SELECTION-SCREEN BEGIN OF SCREEN 100.

parameter p_val1 type char10.

SELECTION-SCREEN END OF SCREEN 100.

SELECTION-SCREEN BEGIN OF SCREEN 200.

parameter p_val2 type char10.

SELECTION-SCREEN END OF SCREEN 200.

AT SELECTION-SCREEN.

if rb1 = 'X'.

call selection-screen 100.

else.

call selection-screen 200.

Regards,

Joy.

8 REPLIES 8
Read only

Former Member
0 Likes
3,603

Hi

Firstly create two screens lets say screen 100 and 200

if radio_button1 = 'X'

call screen 100

elseif radio_button2 = 'X'

call screen 200

endif .

Regards

Hitesh

Read only

Former Member
0 Likes
3,603

You can do this in SE80 creating 3 screens and in each whtever buttons, parameters. etc u require.

on button click u can call the 2nd screen and so on

Read only

Former Member
0 Likes
3,603

Hi,

Group all the selection fields as per their selection screen using

and use

at selection-screen output.

Loop at screen.

here u active the slection group u want based on radio btton selection and hide the other 2 selection screens.

endloop.

Read only

Former Member
0 Likes
3,604

Try this code:

REPORT ZDYNAMIC_PROGRAM.

PARAMETERS: rb1 RADIOBUTTON GROUP ab MODIF ID bl2,

rb2 RADIOBUTTON GROUP ab MODIF ID bl2.

SELECTION-SCREEN BEGIN OF SCREEN 100.

parameter p_val1 type char10.

SELECTION-SCREEN END OF SCREEN 100.

SELECTION-SCREEN BEGIN OF SCREEN 200.

parameter p_val2 type char10.

SELECTION-SCREEN END OF SCREEN 200.

AT SELECTION-SCREEN.

if rb1 = 'X'.

call selection-screen 100.

else.

call selection-screen 200.

Regards,

Joy.

Read only

Former Member
0 Likes
3,603

hi,

Try the below code.

If radio_button1 = 'X'.

leave to screen 200.

Elseif

radio_button2 = 'X'.

leave to screen 300.

endif.

Reward points if useful.

Regards,

Aleem.

Read only

0 Likes
3,603

Hey Thank You all...my issue is solved

Thanks Again

Read only

0 Likes
3,603

This message was moderated.

Read only

Sergiu
Contributor
0 Likes
3,603

https://stackoverflow.com/questions/24116362/how-to-handle-subsequent-selection-screens

REPORT zfoobar.

PARAMETERS p_b01 RADIOBUTTON GROUP cmd.
PARAMETERS p_b02 RADIOBUTTON GROUP cmd.

SELECTION-SCREEN BEGIN OF SCREEN 1100.
PARAMETERS p_einri TYPE einri OBLIGATORY.
SELECTION-SCREEN END OF SCREEN 1100.

SELECTION-SCREEN BEGIN OF SCREEN 1200.
PARAMETERS p_bukrs TYPE bukrs OBLIGATORY.
SELECTION-SCREEN END OF SCREEN 1200.

START-OF-SELECTION.
  IF p_b01 = abap_true.
    CALL SELECTION-SCREEN 1100.
    IF sy-subrc = 0. "The most tricky code line
      PERFORM processing_b01.
    ENDIF.
  ELSEIF p_b02 = abap_true.
    CALL SELECTION-SCREEN 1200.
    IF sy-subrc = 0. "The most tricky code line
       PERFORM processing_b02.
    ENDIF.
  ENDIF.

SAP DEMO REPORTS.

REPORT demo_sel_screen_as_subscreen. 
REPORT demo_call_selection_screen. 
REPORT demo_sel_screen_pushbutton.

https://abapinho.com/en/2012/04/botoes-no-ecra-de-seleccao/