We're using a RelayCommand<T> with both an execute and canExecute delegate in our view model.
In XAML, we bind Button.Command to the command and Button.CommandParameter to the selected item of ListBox.
In version 4, whenever the user changes the SelectedItem of the ListBox, the RelayCommand<T>.CanExecute is re-evaluated with the new command parameter value.
After upgrading to version 5, the RelayCommand<T>.CanExecute is never evaluated. Not when the Window is loaded (because the command parameter is null at that moment), but also not when an item is selected in the list box.
Please fix!
Thanks,
Joost
Comments: Hi Laurent, I can confirm both. We always download the latest MVVM Light from the nuget repository. Joost
In XAML, we bind Button.Command to the command and Button.CommandParameter to the selected item of ListBox.
In version 4, whenever the user changes the SelectedItem of the ListBox, the RelayCommand<T>.CanExecute is re-evaluated with the new command parameter value.
After upgrading to version 5, the RelayCommand<T>.CanExecute is never evaluated. Not when the Window is loaded (because the command parameter is null at that moment), but also not when an item is selected in the list box.
Please fix!
Thanks,
Joost
Comments: Hi Laurent, I can confirm both. We always download the latest MVVM Light from the nuget repository. Joost