There is a bug in the RadGridView when using built in filters.
If I filter a grid by a value that returns a single row, the row is visibly selected but and I get a System.NullReferenceException, if I try to get a cell value when the SelectionChanged event is fired. When I handle the exception, and I then click on the row, it does not fire the SelectionChanged event.
I have to set .CurrentRow = Nothing on FilterChanged in order to click on and select the row, which will then fire the SelectChanged event and I get the value expected.
Here is my relevant code to reproduce the issue;
Private Sub RadGridViewFullBadge_SelectionChanged(sender As Object, e As EventArgs) Handles RadGridViewFullBadge.SelectionChanged
'This If Statement is Required or I get a System.NullReferenceException after the filter is applied
If RadGridViewFullBadge.CurrentRow IsNot Nothing Then
RadTextBoxControlTestBadge.Text = RadGridViewFullBadge.CurrentRow.Cells("BadgeID").Value
End If
End Sub
Private Sub RadGridViewFullBadge_FilterChanged(sender As Object, e As GridViewCollectionChangedEventArgs) Handles RadGridViewFullBadge.FilterChanged
RadGridViewFullBadge.CurrentRow = Nothing
End Sub
James