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

[Solved] Setting GridViewCell.BackgroundColor at runtime

2 Answers 83 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Francois Lamy
Top achievements
Rank 1
Francois Lamy asked on 29 Jan 2010, 02:33 PM
I am using the RadGridView with EnableRowVirtualization=true and  I want to set the backgroundcolor on a cell at runtime depending on some data that is associated with the record.  More precisely, I have a checkbox column that when checked should disable and gray out the other cells in the row and when unchecked should enable the other cells in the row and set the background color to white.  What is the best way to accomplish this?

2 Answers, 1 is accepted

Sort by
0
Accepted
Pavel Pavlov
Telerik team
answered on 03 Feb 2010, 04:04 PM
Hi Thomas Whittaker,

I have tried to resemble your scenario in tha attached sample project.
Let me know if you find any troubles adapting this to your project,

All the best,
Pavel Pavlov
the Telerik team

Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Follow the status of features or bugs in PITS and vote for them to affect their priority.
0
Francois Lamy
Top achievements
Rank 1
answered on 04 Feb 2010, 05:10 PM
Thanks Pavel!  That did the trick and worked great.  Don't know why I didn't think to do it that way myself...
Tags
GridView
Asked by
Francois Lamy
Top achievements
Rank 1
Answers by
Pavel Pavlov
Telerik team
Francois Lamy
Top achievements
Rank 1
Share this question
or