Did you try to use the SelectedIndexChange of the treeview control?
It has an argument: TreeViewSelectEventArgs which provides you with the
index newnode being selected. (e.newNode returns the index of the selected
node. You could use TreeView.GetNodeFromIndex(string index) to get a
reference of the seelcted node).
For example,
create the SelectedIndexChange for the treeview and add the following code
in it:
TreeNonde tn = TreeView1.GetNodeFromIndex(e.NewNode)
This line would return to you the node that was selected
Regards
Mohamed El Ashmawy
MEA Developer Support Center
ITWorx on behalf of Microsoft EMEA GTSC
|