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

Selection screen control with check box...

Former Member
0 Likes
2,133

Hi Gurus,

I have a selection screen for Custom SAP report. There is master check box and then 5 other check boxes. If I uncheck Master Check box, I want all other check boxes to be unchecked and invisible. And when I check master check box, I want all of them to be checked.

How can I achieve this using loop at screen---endloop ?

Regards,

TS

Moderator message: FAQ, please search for information before posting.

Message was edited by: Thomas Zloch

Hi Gurus,

I have a selection screen for Custom SAP report. There is master check box and then 5 other check boxes. If I uncheck Master Check box, I want all other check boxes to be unchecked and invisible. And when I check master check box, I want all of them to be checked.

How can I achieve this using loop at screen---endloop ?

Regards,

TS

Moderator message: FAQ, please search for information before posting.

Message was edited by: Thomas Zloch

4 REPLIES 4
Read only

Former Member
0 Likes
1,406

Search the forum for MODIF ID. Has been discussed a couple of times.

Read only

0 Likes
1,406

I see the modif id for check boxes controlled with radio button but I want modif id for check boxes controlled with another check box....

Please help...

Read only

0 Likes
1,406

Try the following code:

PARAMETERS:

   p_master   as checkbox default 'X' user-command comm,

   p_box1 as checkbox modif id BOX,

   p_box2 as checkbox modif id BOX.

  

...

AT SELECTION-SCREEN OUTPUT.

LOOP AT SCREEN.
IF  ( P_MASTER = 'X' ) AND ( SCREEN-GROUP1 CS 'BOX' ) .
SCREEN-ACTIVE = '1'.
P_BOX1 = 'X'.

P_BOX2 = 'X.

ENDIF.


IF
( P_MASTER = ' ' ) AND ( SCREEN-GROUP1 CS 'BOX' ) .
SCREEN-ACTIVE = '0'.

P_BOX1 = ' '.

P_BOX2 = ' '.
ENDIF.

MODIFY SCREEN.
ENDLOOP.


Read only

Former Member
0 Likes
1,406

Hi T S,

You just need to put a condition on your master checkbox and then loop at screen.

If master_checkbox = ' '.

Loop at screen.

*Then here you need to blank out each of your checkboxes, whatever you have called them.

If screen-name = 'BOX1'.

BOX1 = ' '.   "Force the checbox to be blank

screen-input = '0'. "0 to make it display only, 1 to make input possible.

Modify screen.

Endif.

Endloop.

Endif.

Hope this helps!

Mark