treeview expand client-side attribute

G

Guest

i have a treeview
(id="trv")

i would like to do something like this:
trv.Attributes.Add("onexpand", "javascript:alert(this);");


i cannot make this work
i would like to know if this is the way I should do it, or should i
add some event somehow to each node


basically i would like to do some javascript action on each expand -
each (expanded) node
(later on collapse too)


i found this example in articles like this one:
http://p2p.wrox.com/topic.asp?TOPIC_ID=46824


basically i have somthing like this:


nodeSection.NavigateUrl = "javascript:showMenu('Section', " +
rowSection["ContractSectionId"].ToString() + ", " +
rowSection.GetChildRows("SectionToGroup").Length.ToString() + ");";


i would like to add an other feature like this, only this time i'd
like to do it on expand / collapse ...


thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,534
Members
45,008
Latest member
Rahul737

Latest Threads

Top