# Events

The Telerik UI ActionSheet for ASP.NET MVC [exposes multiple events](https://www.telerik.com/aspnet-mvc/documentation/api/kendo.mvc.ui.fluent/actionsheeteventbuilder) that allow you to control the behavior of the UI component.

For a complete example on basic ActionSheet events, refer to the [demo on using the events of the  ActionSheet](https://demos.telerik.com/aspnet-mvc/actionsheet/events).

The following example demonstrates how you can subscribe to the `Open` and `Close` events of the component.

```Razor HtmlHelper
    @(Html.Kendo().ActionSheet()
        .Name("actionsheet")
        .Title("Select item")
        .Items(items =>
        {
            items.Add().Text("Edit Item").IconClass("k-icon k-i-edit");
            items.Add().Text("Add to Favorites").IconClass("k-icon k-i-heart");
            items.Add().Text("Upload New").IconClass("k-icon k-i-upload");
            items.Add().Text("Cancel").IconClass("k-icon k-i-cancel").Group("bottom");
        })
        .Events(e => 
        {
            e.Open("onOpen");
            e.Close("onClose");
        })
    )

    <script>
        function onOpen() {
            console.log("Open")
            // Custom logic when the ActionSheet opens.
        }

        function onClose() {
            console.log("Close")
            // Custom logic when the ActionSheet closes.
        }
    </script>
```

## Next Steps

* [Using the ActionSheet Events (Demo)](https://demos.telerik.com/aspnet-core/actionsheet/events)

## See Also

* [Using the API of the ActionSheet for ASP.NET MVC (Demo)](https://demos.telerik.com/aspnet-mvc/actionsheet/api)
* [Client-Side API of the ActionSheet](https://docs.telerik.com/kendo-ui/api/ui/actionsheet)
* [Server-Side API of the ActionSheet HtmlHelper](https://www.telerik.com/aspnet-mvc/documentation/api/actionsheet)
