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

TreeView OnSelected event

4 Answers 60 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
swegele
Top achievements
Rank 1
swegele asked on 29 Dec 2015, 12:10 AM

Guys honestly wouldn't it be easy to add an OnClientSelected event to TreeView?  I see you are changing the Div class from "rtBot" to "rtBot rtSelected".  So you know it is happening.  So many people have asked about this over the years and I find it annoying to try and do a hack with the OnKeyPressed.

 Please?

 

Sean

 

4 Answers, 1 is accepted

Sort by
0
swegele
Top achievements
Rank 1
answered on 29 Dec 2015, 04:38 AM
If you can't do OnClientNodeSeledted then how about a OnClientNodeHighlighted event?
0
Ivan Danchev
Telerik team
answered on 31 Dec 2015, 02:41 PM
Hello Sean,

We can suggest logging a feature request in our Feedback Portal for the addition of an OnClientNodeSelected event for the TreeView. Highly demanded features often get implemented in future releases.

Regards,
Ivan Danchev
Telerik
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 Feedback Portal and vote to affect the priority of the items
0
swegele
Top achievements
Rank 1
answered on 31 Dec 2015, 04:59 PM

I added a request.  Thank you.

In the meantime, do you think it is possible using $ jQuery to write a quick example of subscribing to <li> elements in the tree-view watching for addition of the class="rtSelected"?

This might give us a work-around in the meantime?

Thank you.

0
Ivan Danchev
Telerik team
answered on 05 Jan 2016, 01:01 PM
Hello Sean,

You could try Rory's solution posted in the following stackoverflow thread in order to detect a change in the class of the topmost TreeView node's div element (the div with class rtTop):
var $div = $(".rtTop");
Any change of the class will be reflected in the attributeValue variable's value.

Regards,
Ivan Danchev
Telerik
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 Feedback Portal and vote to affect the priority of the items
Tags
TreeView
Asked by
swegele
Top achievements
Rank 1
Answers by
swegele
Top achievements
Rank 1
Ivan Danchev
Telerik team
Share this question
or