change
Triggered when the selection has changed (either by the user or through the select
method).
Example - subscribe to the "change" event during initialization
<div id="treeview"></div>
<script>
$("#treeview").kendoTreeView({
dataSource: [
{ text: "foo", items: [
{ text: "bar" }
] }
],
change: function(e) {
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log("Change", this.select());
}
});
</script>
Example - subscribe to the "change" event after initialization
<div id="treeview"></div>
<script>
function tree_change(e) {
/* The result can be observed in the DevTools(F12) console of the browser. */
console.log("Change", this.select());
}
$("#treeview").kendoTreeView({
dataSource: [
{ text: "foo", items: [
{ text: "bar" }
] }
]
});
var treeview = $("#treeview").data("kendoTreeView");
treeview.bind("change", tree_change);
</script>