After I changed backcolor of GridHeaderCellElement in Element hierachy editor and press F5, an ArgumentOutOfRangeException was thrown. (The exception occured in this piece of code:
((Telerik.WinControls.UI.GridHeaderCellElement)(this.radGridView1.GetChildAt(0).GetChildAt(1).GetChildAt(0).GetChildAt(1))).TextAlignment = System.Drawing.ContentAlignment.MiddleCenter;
((Telerik.WinControls.UI.GridHeaderCellElement)(this.radGridView1.GetChildAt(0).GetChildAt(1).GetChildAt(0).GetChildAt(1))).Text = "CustomerID";
((Telerik.WinControls.UI.GridHeaderCellElement)(this.radGridView1.GetChildAt(0).GetChildAt(1).GetChildAt(0).GetChildAt(1))).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(169)))), ((int)(((byte)(20)))), ((int)(((byte)(20)))));
)
I've strugged with this problem all day. Please help me.
((Telerik.WinControls.UI.GridHeaderCellElement)(this.radGridView1.GetChildAt(0).GetChildAt(1).GetChildAt(0).GetChildAt(1))).TextAlignment = System.Drawing.ContentAlignment.MiddleCenter;
((Telerik.WinControls.UI.GridHeaderCellElement)(this.radGridView1.GetChildAt(0).GetChildAt(1).GetChildAt(0).GetChildAt(1))).Text = "CustomerID";
((Telerik.WinControls.UI.GridHeaderCellElement)(this.radGridView1.GetChildAt(0).GetChildAt(1).GetChildAt(0).GetChildAt(1))).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(169)))), ((int)(((byte)(20)))), ((int)(((byte)(20)))));
)
I've strugged with this problem all day. Please help me.