I'm having an issue with my project. I have a RadGridView populated by a Stored Procedure, I have some Cellformatting in place.
I'm getting some odd behaviour when scrolling, the formatting is being applied to more than just the first 2 columns and the more you scroll the worse it gets.
I'm using an older version but we recently purchased the latest version of telerik for winforms to test and I'm getting the same behaviour in the new project.
Any assistance would be appreciated.
My code for CellFormatting
Private Sub DataGridView2_CellFormatting(sender As Object, e As CellFormattingEventArgs) Handles DataGridView2.CellFormatting
If e.ColumnIndex = 0 Then
e.CellElement.Font = RWLCompleteFont
e.CellElement.ForeColor = Color.Black
e.CellElement.NumberOfColors = 1
e.CellElement.BackColor = Color.LightSteelBlue
e.CellElement.DrawFill = True
e.CellElement.DrawBorder = True
e.CellElement.BorderBoxStyle = Telerik.WinControls.BorderBoxStyle.OuterInnerBorders
End If
If e.ColumnIndex = 1 Then
e.CellElement.Font = RWLDetailsFont
e.CellElement.ForeColor = Color.Black
e.CellElement.NumberOfColors = 1
e.CellElement.BackColor = Color.LightSkyBlue
e.CellElement.DrawFill = True
e.CellElement.DrawBorder = True
e.CellElement.BorderBoxStyle = Telerik.WinControls.BorderBoxStyle.OuterInnerBorders
End If
End Sub