I have a treeview which I put a bunch of Category Numbers in as the Tag of the node. Now after having that category number, in another application I wish to search the Category to get the parent text as well as the current selected text. My code looks like this thus far.
This code came from MSDN, but it never finds my Tag which I know is in it as the other application supplies the values that I am sending back from the same treeview, just copied over to the other app. I have search for hours on this, but the results that I have tried just don't work or have errors that don't correct. For example... A sample of my treeview looks like this...Code:With TreeView1 For Each node As TreeNode In .Nodes If node.Tag = TextBoxCategory.Text Then .SelectedNode = node tbLexicon.Text = .SelectedNode.Parent.Text & " > " & .SelectedNode.Text Exit For End If Next End With
Air Condition and Heating
.........A/C Compressor & Clutch
..................Tag = 33543
.........A/C Hoses & Fittings
..................Tag = 33544
.........A/C & Heater Controls
..................Tag = 33545
Any help much appreciated.




Reply With Quote
