This is a migrated thread and some comments may be shown as answers.

How to bind the header background color for a bound list of items

1 Answer 79 Views
TileView
This is a migrated thread and some comments may be shown as answers.
Ivan
Top achievements
Rank 1
Ivan asked on 29 Jun 2010, 10:26 PM
Hi,

I need to show different tiles with different header background colors, depending on some data in the item. Can you tell me how this can be done.

To explain further: I have a collection of items that contain a property, based on which I need to set the Header color. This list is bound to the TileView using the ItemSource.

I am using the Item Template (& embedded DataTemplate) to bind the header information (Name of the item).

I also need to change the background color of the tile's header based on a secondary property, i.e. ItemValue. I have a ValueConverter setup that will give me the color for the ItemValue.

How do I get this setup to the Header BackGround?

Thanks in advance.

Regards,

Ivan.

1 Answer, 1 is accepted

Sort by
0
Kiril Stanoev
Telerik team
answered on 02 Jul 2010, 09:51 AM
Hi Ivan,

Currently there is no straightforward way to achieve this. To accomplish this scenario you will have to play around with editing the ControlTemplate of RadTileViewItem and RadTileView's ItemTemplate.
I've attached a sample project demonstrating how this can be achieved. We have plans to optimize this process in the future. Have a look at the process and let us know if it helps.

On a side note, I'd like to inform you that we've just released an online tool that allows you to reduce the size of your Silverlight applications. For more information, please visit http://blogs.telerik.com/blogs/posts/10-06-10/telerik_assembly_minifier.aspx

Greetings,
Kiril Stanoev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
TileView
Asked by
Ivan
Top achievements
Rank 1
Answers by
Kiril Stanoev
Telerik team
Share this question
or