‎2008 Aug 18 6:50 AM
Hi ,
I want to change the screen attributes in my dialog program like we do in standard selection screen .
I have 2 radiobuttons and 2 fields in my custom screen and when I select the first radio button 1st field must be enabled when I select 2nd radiobutton the 2nd field must be enabled and 1st must be grayed out
I wrote the code in the following way
my data declarations
DATA : field1(10) , field2(10), r1 VALUE 'X', r2.
MODULE user_command_0343 INPUT.
LOOP AT SCREEN.
IF r1 = 'X' AND screen-group1 = 'G2'.
screen-input = 0.
MODIFY SCREEN.
ELSEIF r2 = 'X' AND screen-group1 = 'G1'.
screen-input = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
CASE sy-ucomm.
WHEN 'CANCEL'.
LEAVE PROGRAM.
ENDCASE.
ENDMODULE.
In my screen I put the modif ids for fields in the Group1 of rescpetive fields
regards
‎2008 Aug 18 7:04 AM
Hi,
"Loop at screen.
....
....
endloop"
you have writen above code in PAI module, but u have to write it in any PBO module.. i m sure it will work for u..
Regards,
Meet
‎2008 Aug 18 6:59 AM
Use
Assign USER-COMMAND (let ir br ACT) to your radio button group & use this code
LOOP AT SCREEN.
IF r1 = 'X' AND screen-group1 = 'G2'.
screen-input = 0.
MODIFY SCREEN.
ELSEIF r2 = 'X' AND screen-group1 = 'G1'.
screen-input = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
below case sy-ucomm when 'ACT'
‎2008 Aug 18 7:28 AM
sorry I forgot to mention I already assigned the User command Ucomm for the radio button group
‎2008 Aug 18 7:03 AM
Hi there,
We have a standard demo program
demo_dynpro_check_radio in se38
Please check the code in th same to learn more
Regards
Byju
‎2008 Aug 18 7:04 AM
Hi,
"Loop at screen.
....
....
endloop"
you have writen above code in PAI module, but u have to write it in any PBO module.. i m sure it will work for u..
Regards,
Meet
‎2008 Aug 18 7:31 AM