SortableEventBuilder

Methods

Start(System.String)

Fires when sortable item drag starts.

For more information see Start event.

Parameters

handler - System.String

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

Example

Razor
 
            @(Html.Kendo().Sortable()
                        .For("#element")
                        .Events(events => events.Start("handler"))
            )
             

Start(System.Func)

Fires when sortable item drag starts.

For more information see Start event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().Sortable()
                       .For("#element")
                       .Events(events => events.Start(
                            @<text>
                            function(e) {
                                //event handling code
                            }
                            </text>
                       ))
             )
             

Move(System.String)

Fires when Sortable's placeholder changes its position.

For more information see Move event.

Parameters

handler - System.String

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

Example

Razor
 
            @(Html.Kendo().Sortable()
                        .For("#element")
                        .Events(events => events.Move("handler"))
            )
             

Move(System.Func)

Fires when Sortable's placeholder changes its position.

For more information see Move event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().Sortable()
                       .For("#element")
                       .Events(events => events.Move(
                            @<text>
                            function(e) {
                                //event handling code
                            }
                            </text>
                       ))
             )
             

End(System.String)

Fires when item dragging ends but before the item's position is changed in the DOM. This event is suitable for preventing the sort action.

For more information see End event.

Parameters

handler - System.String

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

Example

Razor
 
            @(Html.Kendo().Sortable()
                        .For("#element")
                        .Events(events => events.End("handler"))
            )
             

End(System.Func)

Fires when item dragging ends but before the item's position is changed in the DOM. This event is suitable for preventing the sort action.

For more information see End event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().Sortable()
                       .For("#element")
                       .Events(events => events.End(
                            @<text>
                            function(e) {
                                //event handling code
                            }
                            </text>
                       ))
             )
             

Change(System.String)

Fires when item is sorted and the item's position is changed in the DOM.

For more information see Change event.

Parameters

handler - System.String

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

Example

Razor
 
            @(Html.Kendo().Sortable()
                        .For("#element")
                        .Events(events => events.Change("handler"))
            )
             

Change(System.Func)

Fires when item is sorted and the item's position is changed in the DOM.

For more information see Change event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().Sortable()
                       .For("#element")
                       .Events(events => events.Change(
                            @<text>
                            function(e) {
                                //event handling code
                            }
                            </text>
                       ))
             )
             

Cancel(System.String)

Fires when item sorting is canceled by pressing the Escape key.

For more information see Cancel event.

Parameters

handler - System.String

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

Example

Razor
 
            @(Html.Kendo().Sortable()
                        .For("#element")
                        .Events(events => events.Cancel("handler"))
            )
             

Cancel(System.Func)

Fires when item sorting is canceled by pressing the Escape key.

For more information see Cancel event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().Sortable()
                       .For("#element")
                       .Events(events => events.Cancel(
                            @<text>
                            function(e) {
                                //event handling code
                            }
                            </text>
                       ))
             )