Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Radio Buttons

Hi all,

I have two groups of radio buttons on my screen. While display the first radio button from both the groups gets selected by default. How to deselect the first button in teh second group when the screen gets displayed.

Pls help.

Aarthi.M

Tags:
replied

Hi,

pls refer this code :

PARAMETERS: p_radio1 RADIOBUTTON GROUP g1 USER-COMMAND comm,

p_date1 TYPE sy-datum,

p_radio2 RADIOBUTTON GROUP g1 DEFAULT 'X',

p_date2 TYPE sy-datum.

AT SELECTION-SCREEN OUTPUT.

IF p_radio1 = 'X'.

LOOP AT SCREEN.

CASE screen-name.

WHEN 'P_DATE1'.

screen-input = '1'.

WHEN 'P_DATE2'.

screen-input = '0'.

ENDCASE.

MODIFY SCREEN.

ENDLOOP.

ELSEIF p_radio2 = 'X'.

LOOP AT SCREEN.

CASE screen-name.

WHEN 'P_DATE1'.

screen-input = '0'.

WHEN 'P_DATE2'.

screen-input = '1'.

ENDCASE.

MODIFY SCREEN.

ENDLOOP.

ENDIF.

Hope it may be helpful to u.

regards,

Latheesh.

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question