G
Guest
Hi Everybody
I have a string that contains part of a directory structure that will be
created in the future. I want to display this future tree on a treeview for
the user see and then approve it.
I was able to populate the first level of the tree, but I'll need some
information to how populate the child levels of the tree.
For example, if I have the directory (not created on the OS yet):
Dir1
Dir1/Dir2
Dir1/Dir2/Dir3
Now I'm using:
iniSlash = path.IndexOf(@"\");
if(iniSlash != -1)
{
return path.Substring(0, iniSlash);
}
So I get the first directory (Dir1) and I add it to the tree:
TreeNode ChildNode = new TreeNode(rootNode);
aNode.Nodes.Add(ChildNode);
Where the rootNode = path (returned from the string).
How can I select the populated nodes and get the child for each node on the
tree?
Someone has something like this ?
Thanks!
Eduardo
I have a string that contains part of a directory structure that will be
created in the future. I want to display this future tree on a treeview for
the user see and then approve it.
I was able to populate the first level of the tree, but I'll need some
information to how populate the child levels of the tree.
For example, if I have the directory (not created on the OS yet):
Dir1
Dir1/Dir2
Dir1/Dir2/Dir3
Now I'm using:
iniSlash = path.IndexOf(@"\");
if(iniSlash != -1)
{
return path.Substring(0, iniSlash);
}
So I get the first directory (Dir1) and I add it to the tree:
TreeNode ChildNode = new TreeNode(rootNode);
aNode.Nodes.Add(ChildNode);
Where the rootNode = path (returned from the string).
How can I select the populated nodes and get the child for each node on the
tree?
Someone has something like this ?
Thanks!
Eduardo