Question Deselecting Treenode(s)

VentureFree

Well-known member
Joined
Jan 9, 2008
Messages
54
Programming Experience
5-10
Basically, I want to be able to deselect any and all treenodes in a treeview so that none are selected. I would think it would be trivial, but I just can't seem to figure out how. Is it possible to do so? If so, how?

To clarify, I have a treeview in a vb.net app (not asp.net), and it's set up to add nodes below the selected node on the fly. I want to be able to add a node at the top level when no node is selected. I can't do that if it's impossible to not have a node selected.
 
This always happens

I always figure it out right after I post a question. Sorry for wasting space on here. For anyone else wondering, simply do this:
VB.NET:
treeview.SelectedNode = Nothing
 
Back
Top