.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
1,441 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I have a CollectionView in .Net Maui, and this collectionview has items as Label and Image, ImageSource i am getting from URL, also I have bottom tabs, and when I am switching tabs and come back to parent tab, all images are lost in collectionview
preserve the view state when switching tabs. To do this, override the OnDisappearing and OnAppearing methods in the parent page of the CollectionView:
check
protected override void OnDisappearing()
{
base.OnDisappearing();
// Save the view state (e.g., the CollectionView's content)
}
protected override void OnAppearing()
{
base.OnAppearing();
// Restore the view state (e.g., load the CollectionView's content)
}