Change Row Background color based on condition

2 posts, 0 answers
  1. farizvi
    farizvi avatar
    8 posts
    Member since:
    Feb 2007

    Posted 25 Feb Link to this post

    I've been trying to change the row background color in radgridview based on a condition

    [code]

    if(myCondition)

    {

        var row = e.Row;
    Style style = new Style(typeof(GridViewRow));
                    style.BasedOn = e.Row.Style;

    }

    [/code]

  2. Yoan
    Admin
    Yoan avatar
    1069 posts

    Posted 25 Feb Link to this post

    Hello,

    The way to go is to use RowStyleSelector as demonstrated in this help article.

    Regards,
    Yoan
    Telerik
    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 Feedback Portal and vote to affect the priority of the items
  3. DevCraft banner
Back to Top