Events
The Telerik UI for ASP.NET MVC RadioGroup exposes multiple events that allow you to control and customize the behavior of the UI component.
For a complete example on basic RadioGroup events, refer to the demo on using the events of the RadioGroup.
Handling by Handler Name
The following example demonstrates how to subscribe to events by handler name.
@(Html.Kendo().RadioGroup()
.Name("radiogroup")
.Items(i =>
{
i.Add().Label("Two bedroom apartment for multiple people").Value("1");
i.Add().Label("Studio apartment with kitchen").Value("2");
i.Add().Label("Double bed apartment with kids zone").Value("3");
})
.Value("2")
.Events(e => e.Change("onChange"))
)
<script>
function onChange() {
// Handle the change event.
}
</script>
Handling by Template Delegate
The following example demonstrates how to subscribe to events by using a template delegate.
@(Html.Kendo().RadioGroup()
.Name("radiogroup")
.Events(e => e
.Change(@<text>
function() {
// Handle the change event inline.
}
</text>)
)
)