0
Estu trying to add one TreeView Node
by path, for example:
And the code I’m trying is like this:
public void AddParent(string path, string node)
{
TreeNode parentNode = treeView1.Nodes[path];
if (parentNode != null)
{
parentNode.Nodes.Add(node);
}
}
Ex path: Node0 Node1 Node2 Ex No: Testing
But parentNode always returns null
.
Can someone help me?