New to Telerik UI for ASP.NET MVC? Start a free 30-day trial

Defines the fluent interface for configuring ColorPicker client events.

Definition

Constructors

Initializes a new instance of the ColorPickerEventBuilder class.

C#
public SimpleColorPickerEventBuilder(IDictionary<string, object> events)
Parameters:eventsIDictionary<string, object>

The events bag.

Methods

Defines the handler of the Change client-side event.

C#
public SimpleColorPickerEventBuilder Change(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag (Razor syntax).

Returns:

SimpleColorPickerEventBuilder

Example:
C#
@(Html.Kendo().ColorPicker()
.Name("ColorPicker")
.Events(events =&gt; events.Change(
@&lt;text&gt;
function(e) {
// event handling code
}
&lt;/text&gt;
))
)

Defines the handler of the Change client-side event.

C#
public SimpleColorPickerEventBuilder Change(string handler)
Parameters:handlerstring

The name of the JavaScript function that will handle the Change event.

Returns:

SimpleColorPickerEventBuilder

Example:
C#
@(Html.Kendo().ColorPicker()
.Name("ColorPicker")
.Events(events =&gt; events.Change("onChange"))
)
C#
public SimpleColorPickerEventBuilder KendoKeydown(Func<object, object> handler)
Parameters:handlerFunc<object, object>Returns:

SimpleColorPickerEventBuilder

C#
public SimpleColorPickerEventBuilder KendoKeydown(string handler)
Parameters:handlerstringReturns:

SimpleColorPickerEventBuilder