‎2008 Aug 01 12:34 PM
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
‎2008 Aug 01 12:47 PM
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.
‎2008 Aug 01 12:37 PM
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
‎2008 Aug 01 12:38 PM
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
‎2008 Aug 01 12:40 PM
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.
‎2008 Aug 01 12:47 PM
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.
‎2008 Aug 01 12:52 PM
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.
‎2008 Aug 01 1:19 PM
‎2015 Oct 29 12:41 PM
‎2022 Mar 25 10:51 AM
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.