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

Changing Radio Button Default in Dialog Programming

Former Member
0 Likes
1,656

G'day ABAPers,

My problem is - I have 3 radio buttons on a screen I defined.

When the screen is loaded the 1st radio button is defaulted with 'X'.

When the user selects say the 3rd radio button and the screen refreshes - I want the 3rd radio button the be selected. Not the 1st. At the moment it reverts back to the 1st radio button.

Stumping me.

Todd

4 REPLIES 4
Read only

Former Member
0 Likes
870

Hi,

Could you pleae kindly check:

1. If the three radio buttons are set in the same radio button group?

2. If you want to set the 3rd radio button as default, please clear the variants of the other two radio buttons in PBO, and set the 3rd radio button's value to 'X' at the same place.

Cheers,

Read only

0 Likes
870

1. Yes they are.

2. Tried that and it still reverts back to the first radio button.

Read only

0 Likes
870

Hi Slatter,

1) Make sure the radio buttons are grouped in Screen Painter( and you did that) 
2) Activate all the Components of your Module Pool Program ( Screens , Includes, Modules, Flow Logic )
3) Make sure the Variables related to RADIO BUTTONS are declared in TOP Include.
4) Make sure the Screen Field Radio Buttons and Variables related to Radio buttons in TOP Include are same.

for Ex screen field Radio buttons are R1, R2, R3 

in TOP Include.

data : R1 TYPE C, R2 TYPE C, R3 TYPE C. " Optionally you can omit TYPE C.

Cheerz

Ram

Read only

sridhar_meesala
Active Contributor
0 Likes
870

Hi,

Adding to all the above, check whether you have defaulted the first radio button in the PBO like R1 = 'X'. If so, remove that. By default the first radio button will be selected when the screen first appears.

Thanks,

Sri.