Hello,
I'm receiving crashes because of a NullReferenceException in my production app.
I managed to create a demo app that should crash, when you start it.
Steps to reproduce:
1. Debug the demo app.
2. App should crash.
Xamarin Forms version: 4.2.0.778463
SfDataGrid version: 17.2.0.51
Test device: Samsung Galaxy S10, Android 9.0.0
Stack trace:
System.NullReferenceException: Object reference not set to an instance of an object.
at Syncfusion.Data.TraversalHelper.GetPrevious (Syncfusion.Data.NodeEntry entry) [0x000c0] in <2406d789b2e64470814c04162a45ff6e>:0
at Syncfusion.Data.GroupDisplayElements.GetItemAt (System.Int32 index) [0x00062] in <2406d789b2e64470814c04162a45ff6e>:0
at Syncfusion.Data.GroupDisplayElements.get_Item (System.Int32 index) [0x00000] in <2406d789b2e64470814c04162a45ff6e>:0
at Syncfusion.SfDataGrid.XForms.RowGenerator.UpdateDataRow (System.Collections.Generic.IEnumerable`1[T] rows, System.Int32 rowIndex, Syncfusion.SfDataGrid.XForms.RowRegion region) [0x002a6] in <727c0126a200480083f9ae64a03817a9>:0
at Syncfusion.SfDataGrid.XForms.RowGenerator.UpdateRow (System.Collections.Generic.IEnumerable`1[T] rows, System.Int32 rowIndex, Syncfusion.SfDataGrid.XForms.RowRegion region) [0x004c5] in <727c0126a200480083f9ae64a03817a9>:0
at Syncfusion.SfDataGrid.XForms.RowGenerator.EnsureRows (Syncfusion.GridCommon.ScrollAxis.VisibleLinesCollection visibleRows, Syncfusion.GridCommon.ScrollAxis.VisibleLinesCollection visibleColumns) [0x00188] in <727c0126a200480083f9ae64a03817a9>:0
at Syncfusion.SfDataGrid.XForms.VisualContainer.EnsureItems (System.Boolean needToRefresh) [0x00039] in <727c0126a200480083f9ae64a03817a9>:0
at Syncfusion.SfDataGrid.XForms.VisualContainer.OnSizeAllocated (System.Double width, System.Double height) [0x00260] in <727c0126a200480083f9ae64a03817a9>:0
at Xamarin.Forms.VisualElement.SizeAllocated (System.Double width, System.Double height) [0x00000] in D:\a\1\s\Xamarin.Forms.Core\VisualElement.cs:784
at Xamarin.Forms.Layout.ForceLayout () [0x00000] in D:\a\1\s\Xamarin.Forms.Core\Layout.cs:125
at Syncfusion.SfDataGrid.XForms.GridModel.RefreshDataRow () [0x0003a] in <727c0126a200480083f9ae64a03817a9>:0
at Syncfusion.SfDataGrid.XForms.GridModel.RefreshView () [0x0003c] in <727c0126a200480083f9ae64a03817a9>:0
at Syncfusion.SfDataGrid.XForms.GridModel.OnRecordCollectionChanged (System.Object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x001c6] in <727c0126a200480083f9ae64a03817a9>:0
at Syncfusion.Data.CollectionViewAdv.RaiseCollectionChangedEvent (System.Collections.Specialized.NotifyCollectionChangedEventArgs args) [0x00008] in <2406d789b2e64470814c04162a45ff6e>:0
at Syncfusion.Data.CollectionViewAdv.RefreshView (System.Collections.Specialized.NotifyCollectionChangedEventArgs args) [0x00000] in <2406d789b2e64470814c04162a45ff6e>:0
at Syncfusion.Data.CollectionViewAdv.Refresh (System.Boolean isProgrammatic) [0x0003f] in <2406d789b2e64470814c04162a45ff6e>:0
at Syncfusion.Data.QueryableCollectionView.RefreshFilter (System.Boolean isProgrammatic) [0x0004e] in <2406d789b2e64470814c04162a45ff6e>:0
at SfDataGridBugDemo.MainPage.RefreshFilter () [0x0002e] in C:\Source\SfDataGridBugDemo\SfDataGridBugDemo\SfDataGridBugDemo\MainPage.xaml.cs:93
at SfDataGridBugDemo.MainPage.PlaylistComboBox_OnSelectedIndexChanged (System.Object sender, System.EventArgs e) [0x000b2] in C:\Source\SfDataGridBugDemo\SfDataGridBugDemo\SfDataGridBugDemo\MainPage.xaml.cs:54
at (wrapper dynamic-method) Android.Runtime.DynamicMethodNameCounter.18(intptr,intptr)
at (wrapper native-to-managed) Android.Runtime.DynamicMethodNameCounter.18(intptr,intptr)
Attachment:
SfDataGridBugDemo_44a03b03.zip