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

disabling the parameters in the selection screen

Former Member
0 Likes
2,354

how to disable some parameters in the selection screen if one condition is satisfied asnd to to enable them if other condition is satisfied.

how to disable some parameters in the selection screen if one condition is satisfied asnd to to enable them if other condition is satisfied.

4 REPLIES 4
Read only

former_member386202
Active Contributor
0 Likes
1,035

Hi,

Do like this

SELECTION-SCREEN : BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.

PARAMETERS : p_pres RADIOBUTTON GROUP g1 "Radio button for presentation server

USER-COMMAND radio DEFAULT 'X',

p_appl RADIOBUTTON GROUP g1, "Radio button for application server

p_ptest TYPE c AS CHECKBOX.

SELECTION-SCREEN : END OF BLOCK b1.

SELECTION-SCREEN : BEGIN OF BLOCK b2 WITH FRAME TITLE text-002.

PARAMETERS : p_pifile TYPE rlgrap-filename MODIF ID md1, "Input filename for presentation server

p_pefile TYPE rlgrap-filename MODIF ID md2. "Error filename for presentation server

SELECTION-SCREEN : END OF BLOCK b2.

SELECTION-SCREEN : BEGIN OF BLOCK b3 WITH FRAME TITLE text-003.

PARAMETERS : p_aifile TYPE ibipparms-path MODIF ID md3, "Input filename for application server

p_aefile TYPE ibipparms-path MODIF ID md4. "Error filename for application server

SELECTION-SCREEN : END OF BLOCK b3.

FORM sub_check_server .

IF p_pres EQ c_x.

LOOP AT SCREEN.

IF screen-group1 EQ 'MD3'.

screen-input = c_ok.

screen-active = c_1.

ENDIF.

IF screen-group1 EQ 'MD4'.

screen-input = c_ok.

screen-active = c_1.

ENDIF.

MODIFY SCREEN.

ENDLOOP.

ELSEIF p_appl EQ c_x.

LOOP AT SCREEN.

IF screen-group1 EQ 'MD1'.

screen-input = c_ok.

screen-active = c_1.

ENDIF.

IF screen-group1 EQ 'MD2'.

screen-input = c_ok.

screen-active = c_1.

ENDIF.

MODIFY SCREEN.

ENDLOOP.

ENDIF.

Regards,

Prashant

Read only

Former Member
0 Likes
1,035

The coding is done normally in AT selection-screen Output event.

You are required to loop at SCREEN table.

Screen-name will be same as that of your selection screen parameter.

enabling and disabling screen by using screen-input = 0 & 1.

At the ned don't forget to use MODIFY SCREEN statement.

AT SELECTION-SCREN OUTPUT.

loop at screen.

if screen-name = 'RB1'.

screen-input = 0.

else.

screen-input = 1.

endif.

modify screen.

endloop.

Read only

Former Member
0 Likes
1,035

HI

u can use

IF screen-group1 = 'B1'.

screen-input = '0'.

else .

screen-input = '1'.

endif.

for one condition the screen wil be active and for the other condition it wil be inactive.

Read only

Former Member
0 Likes
1,035

Hi

go through this.in this if u select pdhplant then all the 4 in the another selection screen are disable and if u select ppplant then those are enable.

SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.

PARAMETERS : pdhplant RADIOBUTTON GROUP rb1 USER-COMMAND rad1 DEFAULT 'X',

ppplant RADIOBUTTON GROUP rb1 ." OTHERS

SELECTION-SCREEN END OF BLOCK b1.

SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-002.

PARAMETERS : offspec RADIOBUTTON GROUP rb2 MODIF ID oth ,

linespec RADIOBUTTON GROUP rb2 MODIF ID oth,

line1 RADIOBUTTON GROUP rb2 MODIF ID oth,

line2 RADIOBUTTON GROUP rb2 DEFAULT 'X' MODIF ID oth.

SELECTION-SCREEN END OF BLOCK b2.

*----


*AT SELECTION-SCREEN OUTPUT

*----


AT SELECTION-SCREEN OUTPUT.

IF pdhplant EQ 'X'.

LOOP AT SCREEN.

IF screen-group1 = 'OTH'.

screen-input = 0.

ENDIF.

MODIFY SCREEN.

ENDLOOP.

ENDIF.