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

Alternate row not changing background color

1 Answer 26 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Mohammad
Top achievements
Rank 1
Mohammad asked on 03 Dec 2018, 01:12 PM
RadGridview not changing alternate row on radgridview.Rows.Move(0, 2) . AlternatingRowColor and property remain same.

1 Answer, 1 is accepted

Sort by
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 04 Dec 2018, 09:21 AM
Hello, Mohammad,    

Note that 0 and 2 are even numbers. That is why when the EnableAlternatingRowColor property is set to true, the rows at index 0 and 2 would have the same color. However, if you move the row to an odd index, its visual state won't be updated until you hover the cells or force a refresh operation. 

I have logged it in our feedback portal. You can track its progress, subscribe for status changes and add your comments on the following link - feedback itI have also updated your Telerik points.

Currently, the possible solution that I can suggest is to refresh the row you move: 

private void radButton1_Click(object sender, EventArgs e)
{
    this.radGridView1.Rows.Move(0, 5);
    this.radGridView1.Rows[5].InvalidateRow();
}

I hope this information helps.

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
GridView
Asked by
Mohammad
Top achievements
Rank 1
Answers by
Dess | Tech Support Engineer, Principal
Telerik team
Share this question
or