System.Windows.Input.ICommand.CanExecute Method

Defines the method that determines whether the command can execute in its current state.

Syntax

public Boolean CanExecute (Object parameter)

Parameters

parameter
Data used by the command. If the command does not require data to be passed, this object can be set to null.

Returns

true if this command can be executed; otherwise, false.

Remarks

Typically, a command source calls the ICommand.CanExecute(Object) method when the ICommand.CanExecuteChanged event is raised.

Requirements

Namespace: System.Windows.Input
Assembly: System (in System.dll)
Assembly Versions: 4.0.0.0