New to Telerik UI for WinForms? Start a free 30-day trial

Routes execution and availability checks to a command exposed by a RadRichTextBox's command collection.

The command is resolved from the editor's Commands collection using its name followed by Command.

Definition

Namespace:Telerik.WinForms.Documents.RichTextBoxCommands

Assembly:Telerik.WinControls.RichTextEditor.dll

Syntax:

C#
public class RichTextBoxRoutedCommand : RoutedUICommand, ICommand

Inheritance: objectRoutedCommandRoutedUICommandRichTextBoxRoutedCommand

Implements: ICommand

Inherited Members RoutedUICommand.NameRoutedUICommand.TextRoutedCommand.CanExecute(object)RoutedCommand.Execute(object)RoutedCommand.CanExecuteChanged

Constructors

Creates a routed-command identifier that resolves the corresponding command on each editor.

C#
public RichTextBoxRoutedCommand(string name)
Parameters:namestring

The routed-command name and the prefix of the corresponding command-collection property.

Methods

Checks whether the matching command from the specified editor's command collection can execute.

C#
public bool CanExecute(object parameter, RadRichTextBox radRichTextBox)
Parameters:parameterobject

The command-specific parameter forwarded to the editor command.

radRichTextBoxRadRichTextBox

The editor whose command collection supplies the command.

Returns:

bool

true if the command exists and can execute; otherwise, false.

Executes the matching command from the specified editor's command collection when one is available.

C#
public void Execute(object parameter, RadRichTextBox radRichTextBox)
Parameters:parameterobject

The command-specific parameter forwarded to the editor command.

radRichTextBoxRadRichTextBox

The editor whose command collection supplies the command.