ListViewEventBuilder

Methods

Cancel(System.String)

Fired when the user clicks the "cancel" button.The event handler function context (available via the this keyword) will be set to the widget instance.

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().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(events => events.Cancel("onCancel"))
             )
             

Cancel(System.Func)

Fired when the user clicks the "cancel" button.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see Cancel event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(e => e.Cancel(
                           @<text>
                              function(e){
                                  event handling code
                              }
                           </text>
                  ))
            )
             

Change(System.String)

Fires when the ListView selection has changed.The event handler function context (available via the this keyword) will be set to the widget instance.

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().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(events => events.Change("onChange"))
             )
             

Change(System.Func)

Fires when the ListView selection has changed.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see Change event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(e => e.Change(
                           @<text>
                              function(e){
                                  event handling code
                              }
                           </text>
                  ))
            )
             

DataBound(System.String)

Fires when the ListView has received data from the DataSource and it is already rendered.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see DataBound event.

Parameters

handler - System.String

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

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(events => events.DataBound("onDataBound"))
             )
             

DataBound(System.Func)

Fires when the ListView has received data from the DataSource and it is already rendered.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see DataBound event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(e => e.DataBound(
                           @<text>
                              function(e){
                                  event handling code
                              }
                           </text>
                  ))
            )
             

DataBinding(System.String)

Fires when the ListView is about to be bound.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see DataBinding event.

Parameters

handler - System.String

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

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(events => events.DataBinding("onDataBinding"))
             )
             

DataBinding(System.Func)

Fires when the ListView is about to be bound.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see DataBinding event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(e => e.DataBinding(
                           @<text>
                              function(e){
                                  event handling code
                              }
                           </text>
                  ))
            )
             

Edit(System.String)

Fires when the ListView enters edit mode.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see Edit event.

Parameters

handler - System.String

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

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(events => events.Edit("onEdit"))
             )
             

Edit(System.Func)

Fires when the ListView enters edit mode.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see Edit event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(e => e.Edit(
                           @<text>
                              function(e){
                                  event handling code
                              }
                           </text>
                  ))
            )
             

Remove(System.String)

Fires when the list view item is removed. If the event is not prevented, the ListView will call the DataSource sync method.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see Remove event.

Parameters

handler - System.String

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

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(events => events.Remove("onRemove"))
             )
             

Remove(System.Func)

Fires when the list view item is removed. If the event is not prevented, the ListView will call the DataSource sync method.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see Remove event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(e => e.Remove(
                           @<text>
                              function(e){
                                  event handling code
                              }
                           </text>
                  ))
            )
             

Save(System.String)

Fired when a data item is saved.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see Save event.

Parameters

handler - System.String

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

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(events => events.Save("onSave"))
             )
             

Save(System.Func)

Fired when a data item is saved.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see Save event.

Parameters

handler - System.Func<Object,Object>

The handler code wrapped in a text tag.

Example

Razor
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(e => e.Save(
                           @<text>
                              function(e){
                                  event handling code
                              }
                           </text>
                  ))
            )