Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
75
Change header style on sort
posted

Hi,

I am having problems changing the background color of the header in a column when sorting by that column. I am trying to set the color in the

UltraWebGrid1_SortColumn function, and it appears that i can set the value ok, but it is not doing the display. the code is as follows.

Private Sub UltraWebGrid1_SortColumn(ByVal sender As Object, ByVal e As Infragistics.WebUI.UltraWebGrid.SortColumnEventArgs) Handles UltraWebGrid1.SortColumn

Dim uwgcol As Infragistics.WebUI.UltraWebGrid.UltraGridColumn
For Each uwgcol In UltraWebGrid1.Columns
If uwgcol.SortIndicator <> Infragistics.WebUI.UltraWebGrid.SortIndicator.None Then
uwgcol.Header.Style.BackColor = Color.Aquamarine
Else
uwgcol.Header.Style.BackColor = Color.Moccasin
End If
Next
End Sub

Any thoughts on what i am doing wrong and why i can't set the background color?