Application Development 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: 

SALV - Conditional Format

Former Member
0 Kudos
286

Hi,

I am writing a report.

the report will print a log using SALV( cl_salv_table).

i am wondering if  it posible to have diffrent color of the coulmn cell base on the value of the cell?

Thanks in Advance,

Elad

2 REPLIES 2

Former Member
0 Kudos
110

Yes, you can set colour for a cell in SALV. You can search for a particular condition and set the color accordingly.

DATA:  lo_cols TYPE REF TO cl_salv_columns_table,

           lo_col_single TYPE REF TO cl_salv_column_table,

            ls_color TYPE lvc_s_colo.

lo_cols = c_alv->get_columns().

lo_col_single ? = lo_cols->get_column('Your Column Name').

ls_color-col = col_total.

lo_col_tab->set_Color( ls_color ).

Former Member
0 Kudos
110

Moderator message - there is a great deal of information about colouring ALV cells in SCN. Please look for material before asking here.

Locked.

Rob