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 AutoComplete events.

Definition

Constructors

Initializes a new instance of the AutoCompleteEventBuilder class.

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

The client events.

Methods

Defines the handler of the Change client-side event. Fires when the value of the AutoComplete is changed by the user.

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

The handler code wrapped in a text tag.

Returns:

AutoCompleteEventBuilder

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

Defines the handler of the Change client-side event. Fires when the value of the AutoComplete is changed by the user.

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

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

Returns:

AutoCompleteEventBuilder

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

Defines the handler of the Close client-side event. Fires when the suggestion popup of the AutoComplete is closed by the user.

C#
public AutoCompleteEventBuilder Close(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag.

Returns:

AutoCompleteEventBuilder

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

Defines the handler of the Close client-side event. Fires when the suggestion popup of the AutoComplete is closed by the user.

C#
public AutoCompleteEventBuilder Close(string handler)
Parameters:handlerstring

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

Returns:

AutoCompleteEventBuilder

Example:
C#
@( Html.Kendo().AutoComplete()
.Name("AutoComplete")
.Events(events =&gt; events
.Close("onClose")
)
)

Defines the handler of the DataBound client-side event. Fires when the AutoComplete is bound to data from its data source.

C#
public AutoCompleteEventBuilder DataBound(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag.

Returns:

AutoCompleteEventBuilder

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

Defines the handler of the DataBound client-side event. Fires when the AutoComplete is bound to data from its data source.

C#
public AutoCompleteEventBuilder DataBound(string handler)
Parameters:handlerstring

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

Returns:

AutoCompleteEventBuilder

Example:
C#
@( Html.Kendo().AutoComplete()
.Name("AutoComplete")
.Events(events =&gt; events
.DataBound("onDataBound")
)
)

Defines the handler of the Filtering client-side event. Fires when the AutoComplete is about to filter the data source.

C#
public AutoCompleteEventBuilder Filtering(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag.

Returns:

AutoCompleteEventBuilder

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

Defines the handler of the Filtering client-side event. Fires when the AutoComplete is about to filter the data source.

C#
public AutoCompleteEventBuilder Filtering(string handler)
Parameters:handlerstring

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

Returns:

AutoCompleteEventBuilder

Example:
C#
@( Html.Kendo().AutoComplete()
.Name("AutoComplete")
.Events(events =&gt; events
.Filtering("onFiltering")
)
)

Defines the inline handler of the KendoKeydown client-side event

C#
public virtual AutoCompleteEventBuilder KendoKeydown(Func<object, object> handler)
Parameters:handlerFunc<object, object>

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

Returns:

AutoCompleteEventBuilder

Defines the name of the JavaScript function that will handle the KendoKeydown client-side event.

C#
public virtual AutoCompleteEventBuilder KendoKeydown(string handler)
Parameters:handlerstring

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

Returns:

AutoCompleteEventBuilder

Defines the handler of the Open client-side event. Fires when the suggestion popup of the AutoComplete is opened by the user.

C#
public AutoCompleteEventBuilder Open(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag.

Returns:

AutoCompleteEventBuilder

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

Defines the handler of the Open client-side event. Fires when the suggestion popup of the AutoComplete is opened by the user.

C#
public AutoCompleteEventBuilder Open(string handler)
Parameters:handlerstring

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

Returns:

AutoCompleteEventBuilder

Example:
C#
@( Html.Kendo().AutoComplete()
.Name("AutoComplete")
.Events(events =&gt; events
.Open("onOpen")
)
)

Defines the handler of the Select client-side event. Fires when an item from the suggestion popup is selected by the user.

C#
public AutoCompleteEventBuilder Select(Func<object, object> handler)
Parameters:handlerFunc<object, object>

The handler code wrapped in a text tag.

Returns:

AutoCompleteEventBuilder

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

Defines the handler of the Select client-side event. Fires when an item from the suggestion popup is selected by the user.

C#
public AutoCompleteEventBuilder Select(string handler)
Parameters:handlerstring

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

Returns:

AutoCompleteEventBuilder

Example:
C#
@( Html.Kendo().AutoComplete()
.Name("AutoComplete")
.Events(events =&gt; events
.Select("onSelect")
)
)