Good morning, All
I am going to place the tag propeties at each node. And the tag content will be file path.
But my coding is not working..Can someone help me..
Thnx.
My code to generate treenode tag properties from xml is as below:
Private Sub AddTreeViewChildNodes(ByVal parent_nodes As TreeNodeCollection, ByVal xml_node As XmlNode)
For Each child_node As XmlNode In xml_node.ChildNodes
Dim new_node As TreeNode = parent_nodes.Add(child_node.Name)
'set your tag here
new_node.Tag = child_node.Attributes("Tag")
AddTreeViewChildNodes(new_node.Nodes, child_node)
If new_node.Nodes.Count = 0 Then new_node.EnsureVisible()
Next child_node
End Sub
My xml file is like this :
<Items>
<IT>
<HR Tag="C:\Users\Desktop\IT.txt"><HR>
<Engineer>
<LP />
<List />
</Engineer>
</IT>
</Items>