# ListViewEventBuilder

## Methods

### Cancel(System.String)

Defines the handler of the Cancel client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/cancel) event.

#### Parameters

##### handler - `System.String`

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

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

```
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(events => events.Cancel("onCancel"))
             )
             
```

### Cancel(System.Func)

Defines the handler of the Cancel client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/cancel) event.

#### Parameters

##### handler - `System.Func<Object,Object>`

The handler code wrapped in a text tag.

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### Change(System.String)

Defines the handler of the Change client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/change) event.

#### Parameters

##### handler - `System.String`

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

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

```
 
             @(Html.Kendo().ListView<ProductViewModel>()
                  .Name("productsListView")
                  .Events(events => events.Change("onChange"))
             )
             
```

### Change(System.Func)

Defines the handler of the Change client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/change) event.

#### Parameters

##### handler - `System.Func<Object,Object>`

The handler code wrapped in a text tag.

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### DataBound(System.String)

Defines the handler of the DataBound client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/databound) event.

#### Parameters

##### handler - `System.String`

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

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### DataBound(System.Func)

Defines the handler of the DataBound client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/databound) event.

#### Parameters

##### handler - `System.Func<Object,Object>`

The handler code wrapped in a text tag.

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### DataBinding(System.String)

Defines the handler of the DataBinding client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/databinding) event.

#### Parameters

##### handler - `System.String`

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

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### DataBinding(System.Func)

Defines the handler of the DataBinding client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/databinding) event.

#### Parameters

##### handler - `System.Func<Object,Object>`

The handler code wrapped in a text tag.

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### Edit(System.String)

Defines the handler of the Edit client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/edit) event.

#### Parameters

##### handler - `System.String`

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

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### Edit(System.Func)

Defines the handler of the Edit client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/edit) event.

#### Parameters

##### handler - `System.Func<Object,Object>`

The handler code wrapped in a text tag.

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### Remove(System.String)

Defines the handler of the Remove client-side event. Fires before the list view item is put in edit mode. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/remove) event.

#### Parameters

##### handler - `System.String`

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

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### Remove(System.Func)

Defines the handler of the Remove client-side event. Fires before the list view item is put in edit mode. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/remove) event.

#### Parameters

##### handler - `System.Func<Object,Object>`

The handler code wrapped in a text tag.

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### Save(System.String)

Defines the handler of the Save client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/save) event.

#### Parameters

##### handler - `System.String`

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

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### Save(System.Func)

Defines the handler of the Save client-side event. 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](https://docs.telerik.com/kendo-ui/api/ui/listview/events/save) event.

#### Parameters

##### handler - `System.Func<Object,Object>`

The handler code wrapped in a text tag.

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

#### Example

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

### KendoKeydown(System.String)

Defines the handler of the KendoKeydown client-side event. Triggered when the user presses a keyboard key while the ListView is focused.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see [KendoKeydown](https://docs.telerik.com/kendo-ui/api/ui/listview/events/kendokeydown) event.

#### Parameters

##### handler - `System.String`

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

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .

### KendoKeydown(System.Func)

Defines the handler of the KendoKeydown client-side event. Triggered when the user presses a keyboard key while the ListView is focused.The event handler function context (available via the this keyword) will be set to the widget instance.

For more information see [KendoKeydown](https://docs.telerik.com/kendo-ui/api/ui/listview/events/kendokeydown) event.

#### Parameters

##### handler - `System.Func<Object,Object>`

The handler code wrapped in a text tag.

#### RETURNS

Returns the current instance of [ListViewEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/listvieweventbuilder) .
