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

make check box disappear

Former Member
0 Likes
1,117

In a selection screen, how do i make check boxes disappear for a specific tcode.

does this code work below:

loop at screen.

if tcode = ' xyz'.

if screen-name = 'CHK1'.

screen-input = 0.

screen-invisible = 1.

modify screen.

endif.

endif.

endloop.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,053

Hi,

you can try this code:


*specify the parameter of your checkbox.
PARAMETER : p_check AS CHECKBOX.


* Event at screen PBO
AT SELECTION-SCREEN OUTPUT.

  LOOP AT SCREEN.
    IF screen-NAME = 'P_CHECK'   "Check the screen name
    AND sy-tcode = 'SE38'.       "Check for your t-code
      screen-invisible = 1.      "if satisfy, set the invisible on
      MODIFY SCREEN.             "and modify the screen properties
    ENDIF.
  ENDLOOP.

Have a nice try

Hi,

you can try this code:


*specify the parameter of your checkbox.
PARAMETER : p_check AS CHECKBOX.


* Event at screen PBO
AT SELECTION-SCREEN OUTPUT.

  LOOP AT SCREEN.
    IF screen-NAME = 'P_CHECK'   "Check the screen name
    AND sy-tcode = 'SE38'.       "Check for your t-code
      screen-invisible = 1.      "if satisfy, set the invisible on
      MODIFY SCREEN.             "and modify the screen properties
    ENDIF.
  ENDLOOP.

Have a nice try

6 REPLIES 6
Read only

Former Member
0 Likes
1,054

Hi,

you can try this code:


*specify the parameter of your checkbox.
PARAMETER : p_check AS CHECKBOX.


* Event at screen PBO
AT SELECTION-SCREEN OUTPUT.

  LOOP AT SCREEN.
    IF screen-NAME = 'P_CHECK'   "Check the screen name
    AND sy-tcode = 'SE38'.       "Check for your t-code
      screen-invisible = 1.      "if satisfy, set the invisible on
      MODIFY SCREEN.             "and modify the screen properties
    ENDIF.
  ENDLOOP.

Have a nice try

Read only

Former Member
0 Likes
1,053

hi,

in the PBO of the screen ,


loop at screen.

if tcode = ' xyz'.
  if screen-name = 'CHK1'.
     screen-invisible = 1.
      modify screen.
  endif.
endif.

endloop.

regards

gaurav

Read only

Former Member
0 Likes
1,053

Hi

Run this code. Making active = 0 will hide the checkbox.

at selection screen.
loop at screen.
   if screen-name = 'CHK1'.
      if sy-tcode = 'XYZ'.

         screen-active = 0.
modify screen.
endif.
endif.

endloop.

Read only

Former Member
0 Likes
1,053

Hi ,

If you are working on report program.

You need to code your logic in AT SELECTION SCREEN OUTPUT .

Im Module pool program , you need to decide the exact palce depending on your requirement and put code in PAI/PBO.

Hope this helps you.

Read only

Former Member
0 Likes
1,053

>

> does this code work below:

>

why dont you run and check did you !!!

Read only

Former Member
0 Likes
1,053

hi vinay,

try this code

 

AT SELECTION-SCREEN OUTPUT.

loop at screen.
  if sy-tcode = 'XYZ'.
    if screen-name = 'CHK1'.
       screen-active = 0.
       modify screen.
    endif.
endif.
endloop.

Regards,

Abhilash