‎2009 May 05 8:03 AM
IN MODULE POOL CODING HOW TO DYNAMICALLY INACTIVE OR HIDE TABLE CONTROL OR TABLE CONTROL FIELDS
‎2009 May 05 8:12 AM
>
> IN MODULE POOL CODING HOW TO DYNAMICALLY INACTIVE OR HIDE TABLE CONTROL OR TABLE CONTROL FIELDS
Hi,
For any type of table control requirement you can take the help of
RSDEMO02 - Table control demo.
Check here you will find the code how to hide a fields in Table Control.
Regds.
Suman
‎2009 May 05 2:46 PM
loop at screen.
if screen-name = 'table control'.
screen-invisible = '1'.
endif.
modify screen.
endlloop.
Try this out.
‎2009 May 05 3:33 PM
loop at screen.
if screen-name = '<table control name>'.
screen-input = '0'. " input-enabled field - you can use this or below
screen-output = '1'. " display field
screen-activate = '1'. " active field
modify screen.
endif.
endlloop.
Thanks
Satyasuresh Donepudi
‎2009 May 06 8:50 AM
Hi,
To hide controls in table control:-
For that you need to take the group1 for the screen fields that you have taken on screen as ABC and then follow code to disable fields for input in PBO of the screen:-
IF <condition>. "as per your condition
IF screen-group1 = 'ABC'.
LOOP AT SCREEN.
screen-input = 0. "to disable screen fields for input
ENDLOOP.
MODIFY SCREEN.
ENDIF.
ENDIF.
Now say if you want to enable fields for input on some condition then you may use:-
IF <condition>. "as per your condition
IF screen-group1 = 'ABC'.
LOOP AT SCREEN.
screen-input = 1. "to enable screen fields for input
ENDLOOP.
MODIFY SCREEN.
ENDIF.
ENDIF.
Remember that loop at screen only works in PBO of the screen, and not in PAI..
Hope this helps you.
Regards,
Tarun
‎2009 May 06 10:09 AM
hi
try this
in SE51
PBO
loop at screen.
if screen-name = 'XXX'.
SCREEN-ACTIVE = '0'.
SCREEN-INVISIBLE = '1'.
MODIFY SCREEN.
endif.
endloop.
Regards
‎2009 May 06 1:48 PM
set the field tab_cntrl-invisible = 'X'.
TAB_CNTRL is the name of the table control.
TAB_CNTRL is of type CXTAB_CONTROL.
Check the link
http://help.sap.com/saphelp_nw04/helpdata/en/9f/dbac1d35c111d1829f0000e829fbfe/frameset.htm