The SfListView on IOS crashes when navigate to the page and pop then navigate to the page again
The SfListView on IOS crashes when navigate to the page and press back then navigate to the page again with the following exception:
System.InvalidOperationException: VirtualView cannot be null here
at Microsoft.Maui.Handlers.ViewHandler`2[[Microsoft.Maui.IScrollView, Microsoft.Maui, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null],[UIKit.UIScrollView, Microsoft.iOS, Version=18.2.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065]].get_VirtualView()
at Syncfusion.Maui.Core.Internals.ListViewScrollViewHandler.get_ScrollView()
at Syncfusion.Maui.Core.Internals.ListViewScrollViewHandler.OnListViewScrollViewPropertyChanged(Object sender, PropertyChangedEventArgs e)
at Microsoft.Maui.Controls.BindableObject.OnPropertyChanged(String propertyName)
at Microsoft.Maui.Controls.Element.OnPropertyChanged(String propertyName)
at Syncfusion.Maui.ListView.ListViewScrollView.OnPropertyChanged(String propertyName)
at Syncfusion.Maui.ListView.ListViewScrollView.set_ScrollPosition(Double value)
at Syncfusion.Maui.ListView.ListViewLayout.ScrollToRowIndex(Int32 rowIndex, ScrollToPosition scrollToPosition, Boolean animated, Boolean shouldChangeScrollSateToProgramattic)
at Syncfusion.Maui.ListView.SfListView.ScrollTo(Object itemData, ScrollToPosition scrollToPosition, Boolean disableAnimation)
at System.Threading.Tasks.Task.<>c.<ThrowAsync>b__128_0(Object state)
at Foundation.NSAsyncSynchronizationContextDispatcher.Apply() in /Users/builder/azdo/_work/1/s/xamarin-macios/src/Foundation/NSAction.cs:line 179
at Foundation.NSAsyncSynchronizationContextDispatcher.__Registrar_Callbacks__.callback_1528_Foundation_NSAsyncSynchronizationContextDispatcher_Apply(IntPtr pobj, IntPtr sel, IntPtr* exception_gchandle)
Attachment: Archive_2_5aa5b06d.zip
Hi Nguyen Thinh,
We have reviewed your query and prepared a sample with the provided information. It works as expected without any crashes. We have attached the tested sample. Could you please let us know the Maui version you are using? Additionally, could you describe how you're navigating to the ListView page?If possible, modify the attached sample to replicate the issue if any customizations were missed. This will help us to validate it further.
Regards,
Riyas Hameed M
Attachment: ListViewSample_eb5c38b7.zip
sorry for not clarify any clearer, So, the problem lies in the scroll to function in sflistview, when we navigate to the tabview with listview page it wil auto scoll to the lastest item, the first time it work fine, but after navigate back and forth it start to crash in ios the Attachment i've already sent to you have the implement of the scrolltolastest. And about how we're navigating, we have a tabbedpage contain a contentpage with a tabview
ps : Maui: 9.0.80, Syncfusion 30.1.37
public class CTabbedPage : Contentpage
{
private Grid GridView;
private SfTabView TabView;
private PageChatGPT ChatbotPage;
public CPageOther PageOther;
public FTabItem Dashboard, Report, Entry, Notify, Other;
public TabItemCollection TabItemCollection;
private FFloatingButton FloatingButton; }
private async void FloatingButton_Clicked(object? sender, EventArgs e)
{
await SetBusy(true);
if (ChatbotPage == null)
ChatbotPage = new PageChatGPT();
await Application.Current.MainPage.Navigation.PushAsync(ChatbotPage, true);
await SetBusy(false);
}
Nguyen Thinh,
We have reviewed your reported issue and are pleased to inform you that we were able to reproduce the problem. As a result, we have prepared a custom NuGet package (v30.1.37) that includes the fix. You’ll find the package attached below for your reference.
Kindly install the attached package and let us know if it resolves the issue.
Please follow the steps below to test the package:
1.Uninstall the Syncfusion packages from your project.
2.Clear the nuget cache to ensure accurate results (recommended before installing the custom package).
How to install the MAUI custom NuGet in the Windows machine?
3.Now, install the given custom core package.
4. Then, install the required SfListView control package.
The fix will be included in our upcoming NuGet release, scheduled for July 02, 2025.We appreciate your patience and understanding.
Attachment: ListViewPackage_b0a0d745.zip
Hi Nguyen Thinh,
- 4 Replies
- 3 Participants
- Marked answer
-
NT Nguyen Thinh
- Jun 26, 2025 02:26 AM UTC
- Jul 2, 2025 11:12 AM UTC