ASPxClientCommandConsts.BACKCOLOR_COMMAND Property
Identifies a command that changes the color of a back color pickers and sets the selected text back color.
Declaration
static BACKCOLOR_COMMAND: string
Property Value
Type | Description |
---|---|
string | Value: “backcolor” |
Remarks
The BACKCOLOR_COMMAND property can be used in the following ways.
- In the ASPxClientHtmlEditor.CommandExecuted event — to determine the toolbar or ribbon item clicked by an end-user. If the ASPxClientHtmlEditorCommandEventArgs.commandName event parameter returns the BACKCOLOR_COMMAND property value, this means that either the ToolbarBackColorButton toolbar item or the HEBackColorRibbonCommand ribbon item (depending upon the toolbar mode used) has been manipulated by an end-user.
In the ASPxClientHtmlEditor.ExecuteCommand method — to execute the command manually.
In this case, the method requires an additional parameter, which is a string representing a color (in any correct format) to be assigned to the back color pickers (ToolbarBackColorButton, HEBackColorRibbonCommand) and the selected text. You can also execute the method without a parameter to apply the color currently chosen in the back color pickers to the selected text without changing it.
//sets the color of the ToolbarBackColorButton and the selected text back color to red htmlEditor.ExecuteCommand(ASPxClientCommandConsts.BACKCOLOR_COMMAND, 'red');
Note
This command is available only in the Design View.
See Also