How build a MVC TreeView with checkboxes that inherit the the Checked state of the parent Node using loading on demand?
1 Answer, 1 is accepted
0
Accepted
Alex Gyoshev
Telerik team
answered on 04 Aug 2011, 08:14 AM
Hello Denis,
Bind an event handler to the OnDataBound event
In the event handler, set the checked state of the newly loaded items to that of the parent item
However, the dataBound event does not report which node has been updated. In order to make it report it, change the following line in telerik.treeview.js $t.trigger(this.element, 'dataBound');
with $t.trigger(this.element, 'dataBound', { item: $item[0] });
Then you can access the data-bound item through the e.item property of the dataBound event. This change will be included in the next internal build, so you won't have to keep track of it when you upgrade.
Hope this helps,
Alex Gyoshev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items