on 12-08-2005 6:45 AM
hi
i have some 15 select options in my screen.
in my report i want to hide some select options depending on some condition.
i have done this in at selection screen output.
for making the other select-options invisible.
i am using
loop at screen.
screen-invible = 1.
screen-active = 0.
modify screen.
endloop.
can you tell me any other way to make the select-options invisible other the 'no display' and the above logic.
Thanks in advance.
HI Lavaya,
PARAMETER: P_GJAHR TYPE GJAHR.
SELECT-OPTIONS:
SO_1 TYPE ... MODIF ID G1,
SO_2 TYPE ... MODIF ID G2,
SO_3 TYPE ... MODIF ID G3,
AT SELECTION-SCREEN ON p_gjahr.
LOOP AT SCREEN.
IF p_gjahr = '2012'.
IF screen-group1 = 'G1'.
screen-active = 1. "->ACTIVE
MODIFY SCREEN.
ELSE.
screen-active = 0. "->INACTIVE
MODIFY SCREEN.
ENDIF.
elseif p_gjahr = '2013'.
IF screen-group1 = 'G2'.
screen-active = 1.
MODIFY SCREEN.
ELSE.
screen-active = 0.
MODIFY SCREEN.
ENDIF.
ENDIF.
ENDLOOP.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
try AT SELECTION-SCREEN OUTPUT. try to explore the structure screen.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Lavanya
Pls try the below example
selection-screen : begin of block b2.
parameters : rgb1 type c radiobutton group rgb default 'X' modif id mod1 user-command sel ,
rgb2 type c radiobutton group rgb modif id mod2.
selection-screen : end of block b2 .
selection-screen : begin of block b1 .
select-options : s_bukrs for t001w-ekorg modif id m1.
select-options : s_werks for chvw-werks modif id m0 .
selection-screen : end of block b1
at selection-screen output.
if rgb1 = 'X'.
loop at screen.
if screen-group1 = 'M0'.
screen-input = 1.
screen-active = 1.
endif.
modify screen.
if screen-group1 = 'M1'.
screen-input = 0.
screen-active = 0.
endif.
modify screen.
endloop.
endif.
if rgb2 = 'X'.
loop at screen.
if screen-group1 = 'M0'.
screen-input = 0.
screen-active = 0.
screen-invisible = 1.
endif.
if screen-group1 = 'M1'.
screen-input = 1.
screen-active = 1.
endif.
modify screen.
endloop.
endif.
Regards
Suganya
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Lavanya,
You can assign all the select options under a group using a MODIF ID addition to the select option using the syntax:
SELECT-OPTIONS:
S_PTYPE FOR SAPLANE-PLANETYPE MODIF ID ABC.
While you use AT SELECTION-SCREEN OUTPUT, if the condition holds true, then check if the group1 equals the modif id and then make it invisible.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF condition is true.
LOOP AT SCREEN.
IF screen-group1 = 'ABC'. "<MODIF ID>
screen-output = 0.
screen-input = 0.
screen-invisible = 1.
Modify SCREEN.
ENDIF.
ENDLOOP.
ELSE.
<Do the converse>
ENDIF.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
better work with screen-groups:
SELECT-OPTIONS:
GJAHR FOR ANLC-GJAHR MODIF ID Z,
BUKRS FOR ANLC-BUKRS MODIF ID Z,
ANLN1 FOR ANLC-ANLN1 MODIF ID A,
...
LOOP AT SCREEN.
IF SCREEN-GROUP1 = 'Z'.
SCREEN-active = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
Andreas
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Use Radio Buttons or Check box and Based on Your requirement you try to hide or Disable.
vijay
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Lavanya,
I don't think there is another method for hiding select options other than using No Display and Loop at Screen.
Regards,
Sudhakar.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This message was moderated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.