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
The XAML below is for a UWP app uses a VisualStateManager with an IsNullOrEmptyStateTrigger from the Microsoft.Toolkit.Uwp.UI package. The trigger is supposed to disable the button when no items are selected from the ListView. However, the button always remains enabled. The ListView's SelectedItem should be null when nothing in the list is selected (nothing is selected when you first run the app).
Is this bug a regression in the toolkit? If so, what toolkit version did you last see it work:
Steps to Reproduce
Can this be reproduced in the Sample App? (Either in a sample as-is or with new XAML pasted in the editor.) If so, please provide custom XAML or steps to reproduce. If not, let us know why it can't be reproduced (e.g. more complex setup, environment, dependencies, etc...)
Steps to reproduce the behavior:
Create a new Blank App (Universal Windows).
Add the latest Microsoft.Toolkit.Uwp.UI package.
Paste the XAML above into MainPage.xaml.
Run the app and notice that no item is selected in the ListView, but the button is enabled.
Expected behavior
When you run the app, the IsNullOrEmptyStateTrigger should set myButton.IsEnabled = false until an item from the ListView is selected.
Screenshots
No screenshot is necessary.
Environment
NuGet Package(s):
Microsoft.Toolkit.Uwp.UI package (v7.1.2)
Package Version(s):
Windows 10 Build Number:
Fall Creators Update (16299)
April 2018 Update (17134)
October 2018 Update (17763)
May 2019 Update (18362)
May 2020 Update (19041)
Insider Build ({build_number})
App min and target version:
Fall Creators Update (16299)
April 2018 Update (17134)
October 2018 Update (17763)
May 2019 Update (18362)
May 2020 Update (19041)
Insider Build ({build_number})
Device form factor:
Desktop
Xbox
Surface Hub
IoT
Visual Studio version:
2017 (15.{minor_version})
2019 (16.8.3)
2022 (17.{minor_version})
Additional context
N/A
The text was updated successfully, but these errors were encountered:
Hello fmccown, thank you for opening an issue with us!
I have automatically added a "needs triage" label to help get things started. Our team will analyze and investigate the issue, and escalate it to the relevant team if possible. Other community members may also look into the issue and provide feedback 🙌
Nice catch, @fmccown . A similar bug occurs in the toolkit's Sample App, for the IsNullOrEmptyStateTrigger sample page, if you set the trigger on the SelectedItem property of the ListBox.
Describe the bug
The XAML below is for a UWP app uses a VisualStateManager with an IsNullOrEmptyStateTrigger from the Microsoft.Toolkit.Uwp.UI package. The trigger is supposed to disable the button when no items are selected from the ListView. However, the button always remains enabled. The ListView's SelectedItem should be null when nothing in the list is selected (nothing is selected when you first run the app).
Steps to Reproduce
Steps to reproduce the behavior:
Expected behavior
When you run the app, the IsNullOrEmptyStateTrigger should set myButton.IsEnabled = false until an item from the ListView is selected.
Screenshots
No screenshot is necessary.
Environment
NuGet Package(s):
Microsoft.Toolkit.Uwp.UI package (v7.1.2)
Package Version(s):
Windows 10 Build Number:
App min and target version:
Device form factor:
Visual Studio version:
Additional context
N/A
The text was updated successfully, but these errors were encountered: