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

ListBoxEventBuilder

Methods

Add(System.String)

Fires before an item is added to the ListBox.The function context of the event handler (available through the this keyword) that will be set to the component instance.

For more information see Add event.

Parameters

handler - System.String

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

Example


             @( Html.Kendo().ListBox()
                   .Name("listBox")
                   .Events(events => events
                       .Add("handler")
                   )
            )

Change(System.String)

Fires when the ListBox selection has changed.The function context of the event handler (available through the this keyword) that will be set to the component instance.

For more information see Change event.

Parameters

handler - System.String

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

Example


             @( Html.Kendo().ListBox()
                   .Name("listBox")
                   .Events(events => events
                       .Change("handler")
                   )
            )

DataBound(System.String)

Fires when the ListBox has received data from the data source and is already rendered.The function context of the event handler (available through the this keyword) that will be set to the component instance.

For more information see DataBound event.

Parameters

handler - System.String

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

Example


             @( Html.Kendo().ListBox()
                   .Name("listBox")
                   .Events(events => events
                       .DataBound("handler")
                   )
            )

DragStart(System.String)

Fires when the dragging of the ListBox items starts.

For more information see DragStart event.

Parameters

handler - System.String

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

Example


             @( Html.Kendo().ListBox()
                   .Name("listBox")
                   .Events(events => events
                       .DragStart("handler")
                   )
            )

Drag(System.String)

Fires when the placeholder of the ListBox changes its position.

For more information see Drag event.

Parameters

handler - System.String

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

Example


             @( Html.Kendo().ListBox()
                   .Name("listBox")
                   .Events(events => events
                       .Drag("handler")
                   )
            )

Drop(System.String)

Fires when a ListBox item is dropped over one of the drop targets.

For more information see Drop event.

Parameters

handler - System.String

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

Example


             @( Html.Kendo().ListBox()
                   .Name("listBox")
                   .Events(events => events
                       .Drop("handler")
                   )
            )

DragEnd(System.String)

Fires when the dragging of the item ends but before its position is changed in the DOM.

For more information see DragEnd event.

Parameters

handler - System.String

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

Example


             @( Html.Kendo().ListBox()
                   .Name("listBox")
                   .Events(events => events
                       .DragEnd("handler")
                   )
            )

Remove(System.String)

Fires before an item is removed from the ListBox.The function context of the event handler (available through the this keyword) that will be set to the component instance.

For more information see Remove event.

Parameters

handler - System.String

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

Example


             @( Html.Kendo().ListBox()
                   .Name("listBox")
                   .Events(events => events
                       .Remove("handler")
                   )
            )

Reorder(System.String)

Fires when ListBox items are reordered.

For more information see Reorder event.

Parameters

handler - System.String

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

Example


             @( Html.Kendo().ListBox()
                   .Name("listBox")
                   .Events(events => events
                       .Reorder("handler")
                   )
            )

In this article
Not finding the help you need?