New to Telerik UI for ASP.NET Core? Start a free 30-day trial
Events
The OrgChart exposes a variety of events that you can handle and further customize the behavior of the UI component.
For a complete example on the OrgChart events, refer to the OrgChart Events Demo.
Handling by Handler Name
The following example demonstrates how to subscribe to events by a handler name.
Razor
@(Html.Kendo().OrgChart()
.Name("orgchart")
.Events(e => e
.Select("onSelect")
.Change("onChange")
)
)
Handling by Template Delegate
The following example demonstrates how to subscribe to events by a template delegate.
Razor
@(Html.Kendo().OrgChart()
.Name("orgchart")
.Events(e => e
.Select(@<text>
function() {
// Handle the select event inline.
}
</text>)
.Change(@<text>
function() {
// Handle the change event inline.
}
</text>)
)
)