Thanks for your reply.
The key value is set when you add the treenode, right? I can´t seem to access it. Here´s the code:
I also tried using the name property but that didn´t work properly.Code:For Each tvrw In tvds.Tables(0).Rows tvnode = New TreeNode tvnode.Tag = tvrw.Item("Fid") tvnode.Text = tvrw.Item("rubrik").ToString tvnode.ToolTipText = tvrw.Item("info").ToString Faktors.TreeView1.Nodes(0).Nodes.Add(tvnode) If tvnode.Tag.ToString = Evaluate.TextBox7.Text Then Faktors.TreeView1.SelectedNode = tvnode End If Next
How do you think I should do it?
Thanks again.
Fuga.




Reply With Quote