I have implemented a code in which i wanto to colour some cells in the ALV according to a condition.
My code is.
LOOP AT GT_ALVTABLE INTO GW_ALVTABLE. IF GW_ALVTABLE-APLFZ <> '0'. LV_S_COLOR-FNAME = 'NAME1'. LV_S_COLOR-COLOR-COL = 6. "red LV_S_COLOR-COLOR-INT = 1. LV_S_COLOR-COLOR-INV = 0. APPEND LV_S_COLOR TO LV_T_COLOR. GW_ALVTABLE-T_COLOR = LV_T_COLOR. MODIFY GT_ALVTABLE FROM GW_ALVTABLE. ENDIF. ENDLOOP. TRY. GCL_COLUMNS->SET_COLOR_COLUMN( 'T_COLOR' ). CATCH CX_SALV_DATA_ERROR. ENDTRY. GCL_TABLE->DISPLAY( ).
T_COLOR is a column in the GT_ALVTABLE
When i execute it it doesnt colour those cells.
Have i forget something or it cant be done by this way ?
Thx in advance.