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

Defines the fluent API for configuring the Telerik UI for ASP.NET MVC Captcha.client events.

Definition

Constructors

Initializes a new instance of the Captcha class.

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

The client events.

Methods

Defines the handler of the Change client-side event. Fired when users changes the input of the Captcha component.

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

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

Returns:

CaptchaEventBuilder

Example:
C#
@( Html.Kendo().Captcha()
.Name("captcha")
.Events(events =&gt; events.Change("onChange"))
)

Defines the handler of the Error client-side event. Fired when a request triggered by the component fails - can be distinguished via the type argument in the event data.

C#
public CaptchaEventBuilder Error(string handler)
Parameters:handlerstring

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

Returns:

CaptchaEventBuilder

Example:
C#
@( Html.Kendo().Captcha()
.Name("captcha")
.Events(events =&gt; events.Error("onError"))
)

Defines the handler of the RequestEnd client-side event. Fired when a request to a handler is finished - can be distinguished via the type argument in the event data.

C#
public CaptchaEventBuilder RequestEnd(string handler)
Parameters:handlerstring

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

Returns:

CaptchaEventBuilder

Example:
C#
@( Html.Kendo().Captcha()
.Name("captcha")
.Events(events =&gt; events.RequestEnd("onRequestEnd"))
)

Defines the handler of the RequestStart client-side event. Fired when the captcha makes a request to a handler - can be distinguished via the type argument in the event data.

C#
public CaptchaEventBuilder RequestStart(string handler)
Parameters:handlerstring

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

Returns:

CaptchaEventBuilder

Example:
C#
@( Html.Kendo().Captcha()
.Name("captcha")
.Events(events =&gt; events.RequestStart("onRequestStart"))
)