Constructors
RelayCommand
#Initializes a new instance of the RelayCommand class.
Remarks: This constructor allows you to specify whether the command can be executed. If the state of the
canExecute delegate changes, you can call RelayCommand<T>.UpdateCanExecute() to tell the control that is bound to this command to call the delegate again.RelayCommand
#Initializes a new instance of the RelayCommand class.
Remarks: The RelayCommand<T>.CanExecute(object) will always return true.
Parameters:
| execute (Action) | Delegate to execute the command. |
Methods
CanExecute
Determines whether this command can execute with the specified parameter.
Parameters:
| parameter (object) | Command argument from the control. |
Returns:
true if this command can execute; otherwise, false.Parameters:
| parameter (object) | Command argument from the control. |
inherited fromRelayCommand<T>
Parameters:
| e (EventArgs) | Event arguments |
UpdateCanExecute
public void UpdateCanExecute()
Tells consumers of this command that the RelayCommand<T>.CanExecute(object) state has changed and should be queried again.
Events
inherited fromRelayCommand<T>