You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
If you clear an ObservableCollection attached to TabItemsSource, app will crash with ArgumentOutOfRangeException
Steps to reproduce the bug
Steps to reproduce the behavior:
Open XamlControlsGallery project
Modify private void TabViewItemsSourceSample_AddTabButtonClick(TabView sender, object args) in TabViewPage.xaml.cs as follow: myDatas.Clear(); // Add a new MyData item to the collection. TabView automatically generates a TabViewItem. myDatas.Add(CreateNewMyData(myDatas.Count));
Launch the project and add a tab in the TabView page (third exemple)
Expected behavior
Old tabs are removed and the new tab appear
Describe the bug
If you clear an ObservableCollection attached to TabItemsSource, app will crash with ArgumentOutOfRangeException
Steps to reproduce the bug
Steps to reproduce the behavior:
Open XamlControlsGallery project
Modify
private void TabViewItemsSourceSample_AddTabButtonClick(TabView sender, object args)
in TabViewPage.xaml.cs as follow:myDatas.Clear();
// Add a new MyData item to the collection. TabView automatically generates a TabViewItem.
myDatas.Add(CreateNewMyData(myDatas.Count));
Launch the project and add a tab in the TabView page (third exemple)
Expected behavior
Old tabs are removed and the new tab appear
Version Info
NuGet package version:
[Microsoft.UI.Xaml.2.5.0-prerelease.200708003]
It was working on [Microsoft.UI.Xaml.2.4.2]
Additional context
The text was updated successfully, but these errors were encountered: