Class
CommandBinding

Binds a RoutedCommand to the event handlers that implement the command.

Definition

Namespace:Telerik.UI.Xaml.Controls

Assembly:Telerik.WinUI.Controls.dll

Syntax:

cs-api-definition
public class CommandBinding

Inheritance: objectCommandBinding

Constructors

CommandBinding()

Initializes a new instance of the CommandBinding class.

Declaration

cs-api-definition
public CommandBinding()

CommandBinding(ICommand)

Initializes a new instance of the CommandBinding class.

Declaration

cs-api-definition
public CommandBinding(ICommand command)

Parameters

command

ICommand

The command.

CommandBinding(ICommand, ExecutedRoutedEventHandler)

Initializes a new instance of the CommandBinding class.

Declaration

cs-api-definition
public CommandBinding(ICommand command, ExecutedRoutedEventHandler executed)

Parameters

command

ICommand

The command.

executed

ExecutedRoutedEventHandler

The executed.

CommandBinding(ICommand, ExecutedRoutedEventHandler, CanExecuteRoutedEventHandler)

Initializes a new instance of the CommandBinding class.

Declaration

cs-api-definition
public CommandBinding(ICommand command, ExecutedRoutedEventHandler executed, CanExecuteRoutedEventHandler canExecute)

Parameters

command

ICommand

The command.

executed

ExecutedRoutedEventHandler

The executed.

canExecute

CanExecuteRoutedEventHandler

The can execute.

Properties

Command

Gets or sets the ICommand associated with this CommandBinding.

Declaration

cs-api-definition
[TypeConverter(typeof(CommandConverter))]
public ICommand Command { get; set; }

Property Value

ICommand

The command.

Events

CanExecute

Occurs when the command associated with this CommandBinding initiates a check to determine whether the command can be executed on the command target.

Declaration

cs-api-definition
public event CanExecuteRoutedEventHandler CanExecute

Event Value

CanExecuteRoutedEventHandler

Executed

Occurs when the command associated with this CommandBinding executes.

Declaration

cs-api-definition
public event ExecutedRoutedEventHandler Executed

Event Value

ExecutedRoutedEventHandler

PreviewCanExecute

Occurs when the command associated with this CommandBinding initiates a check to determine whether the command can be executed on the current command target.

Declaration

cs-api-definition
public event CanExecuteRoutedEventHandler PreviewCanExecute

Event Value

CanExecuteRoutedEventHandler

PreviewExecuted

Occurs when the command associated with this CommandBinding executes.

Declaration

cs-api-definition
public event ExecutedRoutedEventHandler PreviewExecuted

Event Value

ExecutedRoutedEventHandler