Events
You can subscribe to all TreeMap events.
Handling Events by Handler Name
The following example demonstrates how to subscribe to events by a handler name.
@(Html.Kendo().TreeMap()
.Name("treemap")
.Events(events => events
.ItemCreated("onItemCreated")
.DataBound("onDataBound")
)
)
<script>
function onItemCreated(e) {
// The HTML element.
var element = e.element;
// The dataItem to which the element is bound.
var dataItem = e.sender.dataItem(e.element);
}
function onDataBound(e) {
// Handle the dataBound event.
}
</script>