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

Need to make a Grid legend

1 Answer 37 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Phil Kestenbaum
Top achievements
Rank 1
Phil Kestenbaum asked on 12 Aug 2010, 09:42 PM

 I have to make a 'legend' for a grid that displays the rows in different colours based on the relation of the spending to the budget. Ideally I would like to show a small box the colour in question, with the explanation what it represents. I do not know how to make such a box in colour not how to specify colour on a textblock

 

<TextBlock VerticalAlignment="Center">Green = Below Budget</TextBlock>

 

<TextBlock VerticalAlignment="Center">Yellow = Below Budget in tol.</TextBlock>

 

<TextBlock VerticalAlignment="Center">Red = Over Budget </TextBlock>

 

<TextBlock VerticalAlignment="Center">Orange = Over Budget in Tol.</TextBlock>

 

 

1 Answer, 1 is accepted

Sort by
0
Vanya Pavlova
Telerik team
answered on 13 Aug 2010, 08:53 AM
Hello Phil Kestenbaum,

I have prepared an example for you that demonstrates how to create legend in a column,based on a property of the  underlying object.
Please see the attached example and let me know if it works for you.

All the best,
Vanya Pavlova
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
GridView
Asked by
Phil Kestenbaum
Top achievements
Rank 1
Answers by
Vanya Pavlova
Telerik team
Share this question
or