New to Telerik UI for WinFormsStart a free 30-day trial

Properties

Updated over 6 months ago
PropertyDescription
ColorDialogGets the RadColorDialog of this control.
ColorBoxElementGets the RadColorBoxElement of this control.
ValueGets or sets the value of the editor.
ReadOnlyDetermines if users can input text directly into the text field..
TabStopGets or sets a value indicating whether the user can give the focus to this control using the TAB key.

Events

EventDescription
DialogClosedFires after the color dialog is closed.
ValueChangingFires right before the value is changed, can be canceled.
ValueChangedFires after the editor value is changed.

The ValueChanging event fires before the value is changed and allows you to prevent the change. The event passes a ValueChangingEventArgs parameter that includes the OldValue, NewValue and Cancel properties. Set Cancel to true to prevent the change. The example below cancels the value changing if the new value is not a named color:

Cancel ValueChanging.

C#
private void radColorBox1_ValueChanging(object sender, Telerik.WinControls.UI.ValueChangingEventArgs e)
{
    e.Cancel = !((Color)e.NewValue).IsNamedColor;
}

See Also

In this article
See Also
Not finding the help you need?
Contact Support