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

AlV Using OOPS

Former Member
0 Likes
786

Hi,

Using OOPS i have created Alv .

I have one query .HOw can i color,enable or disable one row

or column or a field in ALV

Can anybody provide me one example.

Thanks in advance.

Chetan

1 ACCEPTED SOLUTION
Read only

Sm1tje
Active Contributor
0 Likes
536

have a look at sample reports starting with BCALV_*. Will be quite a lot, so next do a search on this list.

BCALV_EDIT* would also be a good start.

3 REPLIES 3
Read only

Sm1tje
Active Contributor
0 Likes
537

have a look at sample reports starting with BCALV_*. Will be quite a lot, so next do a search on this list.

BCALV_EDIT* would also be a good start.

Read only

Former Member
0 Likes
536

hi check this....

The coloring functionality in the new ALV OM is done in the following way:

The method SET_COLOR of class CL_SALV_COLUMN_TABLE is used to set the color to the table columns.

For more info pls have a look at the demo prog :"SALV_DEMO_TABLE_COLUMNS"

regards,

venkat appikonda

Read only

uwe_schieferstein
Active Contributor
0 Likes
536

Hello Chetan

The excellent tutorial [An Easy Reference For ALV Grid Control|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/e8a1d690-0201-0010-b7ad-d9719a415907] explains all basic stuff you need to know about ALV including colouring.

You cannot enable or disable rows but you can fix or hide columns via the the fieldcatalog (LVC_S_FCAT).

Example:


LVC_S_FCAT-FIX_COLUMN = 'X'.  " fix column

LVC_S_FCAT-NO_OUT = 'X'.  " column not displayed on initial list but selectable via layout
LVC_S_FCAT-TECH = 'X'.      " column completely hidden for user

Regards

Uwe