2006 Oct 01 5:32 PM
Supose if I have two radio button groups, one with two radio buttons with names RB1 and RB2 with function code R1 and the other group contains three radio buttons with names RB3, RB4 and RB5 with fuction code R2. Now only when I click RB2 of first radio button group the other radio button group should be disabled ( ie radio buttons RB3, RB4 and RB5 must not accept any input)?
Thanks.
Sara.
Supose if I have two radio button groups, one with two radio buttons with names RB1 and RB2 with function code R1 and the other group contains three radio buttons with names RB3, RB4 and RB5 with fuction code R2. Now only when I click RB2 of first radio button group the other radio button group should be disabled ( ie radio buttons RB3, RB4 and RB5 must not accept any input)?
Thanks.
Sara.
2006 Oct 01 5:44 PM
Hi Sara,
Try this..
TABLES: SSCRFIELDS.
PARAMETERS: RB1 RADIOBUTTON GROUP G1 USER-COMMAND UCOMM,
RB2 RADIOBUTTON GROUP G1.
PARAMETER: P_DUMMY TYPE XFELD.
PARAMETERS: RB3 RADIOBUTTON GROUP G2 MODIF ID G2,
RB4 RADIOBUTTON GROUP G2 MODIF ID G2,
RB5 RADIOBUTTON GROUP G2 MODIF ID G2.
AT SELECTION-SCREEN OUTPUT.
IF NOT RB2 IS INITIAL.
LOOP AT SCREEN.
IF SCREEN-GROUP1 = 'G2'.
SCREEN-INPUT = '0'.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
Thanks,
Naren
2006 Oct 01 6:41 PM
2006 Oct 01 6:43 PM
2006 Oct 01 7:16 PM
hello Naren,
what you using in the above code, if you do not mind would you explain about
PARAMETERS: RB1 RADIOBUTTON GROUP G1 USER-COMMAND UCOMM,
RB2 RADIOBUTTON GROUP G1.
PARAMETER: P_DUMMY TYPE XFELD.
PARAMETERS: RB3 RADIOBUTTON GROUP G2 MODIF ID G2,
RB4 RADIOBUTTON GROUP G2 MODIF ID G2,
RB5 RADIOBUTTON GROUP G2 MODIF ID G2.
THANKS.
Sara.
2006 Oct 01 7:20 PM
Hi Sara,
I am giving the user-command for the radio button RB1 for triggering the event AT SELECTION-SCREEN OUTPUT event when the button RB1 or RB2 is pressed.
TABLES: SSCRFIELDS.
PARAMETERS: RB1 RADIOBUTTON GROUP G1 USER-COMMAND UCOMM,
RB2 RADIOBUTTON GROUP G1.
PARAMETER: P_DUMMY TYPE XFELD.
PARAMETERS: RB3 RADIOBUTTON GROUP G2 MODIF ID G2,
RB4 RADIOBUTTON GROUP G2 MODIF ID G2,
RB5 RADIOBUTTON GROUP G2 MODIF ID G2.
LOOP AT SCREEN.
<b> IF SCREEN-GROUP1 = 'G2'.</b>
ENDLOOP.
For the second set of radio buttons I am grouping together using the MODIF ID addition..It will useful when I want to disable the second sets of radio buttons..Otherwise I have to give all the parameters involved in the radio button group G2..
Hope this explains clearly for you..Let me know if you have any questions..
Thanks,
Naren
2006 Oct 01 7:32 PM
Thanks Naren.
I have a question why you used TABLES: SSCRFIELDS and PARAMETER: P_DUMMY TYPE XFELD.?
Pleae do not mind I am new to ABAP.
Sara.
2006 Oct 01 7:37 PM
I just used P_DUMMY just to separate the one set of radio buttons and second set of radio buttons..You can ignore the parameter...
And regarding SSCRFIELDS..you can use if you want to check the user command...You can remove that one also...
Sorry if it had confused you..
THanks,
Naren
2006 Oct 01 7:52 PM
2006 Oct 01 7:56 PM
Please close the thread if you have got the answers..
Thanks
Naren