|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
get the value of the selected node in a treeviewhi
i'm trying to get the value of the selected node in my treeview. my code is: txtTable1.Text = tvRelations.SelectedNode.Parent.ToString but it adds the string 'TreeNode: ' to the value of the node (_56Zones) as such: TreeNode: _56Zones Why ? and how can I get rid of that w/o having to use string functions ? thx "Sam" <samuel.berthe***@voila.fr> schrieb: Use 'SelectedNode.Parent.Text' instead. If you are storing a value in the > i'm trying to get the value of the selected node in my treeview. > my code is: > > txtTable1.Text = tvRelations.SelectedNode.Parent.ToString > > but it adds the string 'TreeNode: ' to the value of the node (_56Zones) > as such: > > TreeNode: _56Zones node's 'Tag' property, use 'SelectedNode.Parent.Tag.ToString()' to convert the value to a string. -- M S Herfried K. Wagner M V P <URL:http://dotnet.mvps.org/> V B <URL:http://classicvb.org/petition/>
Visual Basic .Net List Box
Hiding items in base classes Problems with pictureboxes and memory usage detect mouse event on node of a treeview unbounded array of objects gets error when instantiating elements Adding the same file to multiple projects. How can I loop through all of the messages in the inbox - VB.NET E how to submit a form when enter is pressed newbie stupidity: opening one form and closing another FTP client |
|||||||||||||||||||||||