get the selected node name

  • Thread starter Thread starter rickpayne
  • Start date Start date
R

rickpayne

me.TreeView.GetNodeFromIndex(Me.Treeview.SelectedIndex).text = "some value"
 
I have a treeview in my ASP.NET vb.net application.when someone selects a
node
on the treeview How do I set the node name
myNodeName = TreeView1.Nodes(TreeView1.SelectedNodeIndex).Text
The above code only gave me the value of the parent Node
Any and all help would be greatly appreciated!!!!
 
Hi Rick..!
Thanks.
with a few changes it works..
look
TreeView.GetNodeFromIndex(TreeView.SelectedNodeIndex.ToString).Text

And in this way I can get the text of the user selected node.

Best Regards.
 

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

Back
Top