cancel
Showing results for 
Search instead for 
Did you mean: 

possibility to display different icons in one column of ALV table

0 Kudos

Hi all,

I want to know if there is any possibility to have different icons in one column of ALV table besides using cell variant? For example, i want to display green, red lights when different values. The reason that i don't want to use cell variant is, when using "Export to Excel" funcion of ALV, the cell variant could not be displayed.

thank you and best regards,

Wenwen

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

yes it is possible.

use a context attribute of type string.

bind this context attribute to the alv column.

set the value the context attribute as ' Icon/RedLed' OR 'Icon/YellowLed' or '~Icon/GreenLed'

0 Kudos

Hi Baskaran,

thank you for your reply. But I don't really understand how to do that. Could you give me some coding as example?

best regards,

Wenwen

thomas_jung
Developer Advocate
Developer Advocate
0 Kudos

There is really no code involved. Simply use the icon names as the data that you bind to the context (like any other data). For example fill your internal table with all its data for the table, plus a column that you place the icon names in. Then bind this internal table to the context like you would normally do.

0 Kudos

Hi Baskaran, Hi Thomas,

you are right. It is actually very easy and now I solved the problem. Thank you very much!

best regards,

Wenwen

Edited by: Wenwen Xu on Dec 7, 2010 6:14 PM