on 01-17-2006 11:36 AM
HAI,
I HAVE A TABLE TABLE CONTROL WITH FIVE COLUMNS AND FIVE ROWS, MY REQUIREMENT IS BASED ON SOME CONDITIONHOW TO MAKE A 4TH COLUMN AND ONLY FIRST ROW OF IT AS ONLY OUTPUT ENABLED
CHEERS
In the PBO section of the screen, inside the loop of the table control,
check for the row you want and based on the column(Nothing but the screen name of the field), do synamic screen modifications.
loop at screen.
if screen-name = <your screen field name>.
screen-input = 0.
modify screen.
endif.
endloop.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ho !
loop at itab with control....
module disable_field.
...
endloop.
module disable_fiald.
if sy-tabix = 2 . " second row ! 🙂
** here you can say if value <> 0 for example
loop at screen.
check screen-name = name_of_row4. " only the 4 column
screen-input = 0.
screen-output = 1.
modify screen.
endloop.
endif.
endmodule
endif.
Hi
You can't hide the rows of table control, but you can prevent the input.
You should do it by updating the table screen:
PROCESS PBO.
LOOP.
MODULE LOOP_AT_SCREEN.
ENDLOOP.
MODULE LOOP_AT_SCREEN.
CHECK SY-STEPL > 1.
SCREEN-INPUT = 0.
MODIFY SCREEN.
ENDMODULE.
You can hide the colunm by updating the attribute of table control:
PROCESS PBO.
MODULE UPDATE_TABLE_CONTROL.
LOOP.
MODULE LOOP_AT_SCREEN.
ENDLOOP.
MODULE UPDATE_TABLE_CONTROL.
Fix only on hit
TABLE_CONTROL-LINES = 1.
TYPES-POOLS CXTAB.
DATA: WA_COLUNM TYPE cxtab_column.
LOOP AT TABLE_CONTROL-COLS INTO WA_COLUNM.
IF WA_COLUNM-SCREEN-NAME = .....
WA_COLUNM-INVISIBLE = 'X'.
ENDIF.
MODIFY TABLE_CONTROL-COLS FROM WA_COLUNM.
ENDLOOP.
ENDMODULE.
Max
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
assign one group ,say G1 to that field in column
IN PBO MODULE.
loop at screen.
if screen-group1 = 'G1' and sy-tabix = '1'.
if screen-name = <ur field name>
screen-inout = '0'.
endif.
modify screen.
endloop.
Message was edited by: chandrasekhar jagarlamudi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
In you're pbo you have ...
loop at itab with control .
you should create that
module set_enable.
endloop.
modile set_enable.
loop at screen.
check screen-name = field_to_enable.
check condition met
screen-input = 1.
screen-output = 0.
modify screen
endmodule.
cheerz
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
3 | |
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.