❔ Issue with NotifyCanExecuteChangedFor from MVVM CommunityTK

The problem occurs in my view model (Avalonia MVVM), I set a variable
[ObservableProperty]
[NotifyCanExecuteChangedFor(nameof(PreCheckCommand))]
public string username;

and try to run my function
[RelayCommand]
public void PreCheck() { ... }

whenever the text in to box is changed, it never executes though. Anyone has an idea what the issue is?

This is how I use the binding in my xaml
<TextBox ... Text="{Binding Username, Mode=TwoWay}"></TextBox>
Was this page helpful?