This is a migrated thread and some comments may be shown as answers.

[Solved] How to get the checked state of the selected item

1 Answer 59 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Christopher Ronak
Top achievements
Rank 1
Christopher Ronak asked on 26 Jun 2011, 09:17 PM
Hi there,

Could you please tell me how to get the checked state of a tree item?
Within the onSelect event function, I'd like to be able to determine whether or not the item is checked. Similar to how the onChecked event provides "e.checked", the onSelect event should have the same. 
It would also be nice to have a treeview.isChecked() method similar to the treeview.nodeCheck(nodeisChecked)

Thanks!

Chris

1 Answer, 1 is accepted

Sort by
0
Alex Gyoshev
Telerik team
answered on 27 Jun 2011, 07:09 AM
Hello Christopher,

You can get the checked state through the following code:
node.find(".t-checkbox:first :checkbox").is(":checked");

I think that the client-side method sounds more reasonable than the event argument of the select event - the select event does not need to report such data, but having a convenient method to determine it would make sense. Thank you for the suggestion, we have logged it in the issue tracking system.

All the best,
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
Tags
TreeView
Asked by
Christopher Ronak
Top achievements
Rank 1
Answers by
Alex Gyoshev
Telerik team
Share this question
or