G
Guest
I'm doing a recursive function that receives a TreeNode object. It's
traversing an XMLDocument and putting the data in a TreeView. The problem is
that to start out, I only have a TreeView object. So to add nodes in the
beginning, I have to call
TreeView.Nodes.Add()
But for everything but the top level, I call
TreeNode.Nodes.Add()
It would make my life much easier if I could get a TreeNode reference to the
root node in my TreeView. Is this possible or do I have to completely redo my
logic?
traversing an XMLDocument and putting the data in a TreeView. The problem is
that to start out, I only have a TreeView object. So to add nodes in the
beginning, I have to call
TreeView.Nodes.Add()
But for everything but the top level, I call
TreeNode.Nodes.Add()
It would make my life much easier if I could get a TreeNode reference to the
root node in my TreeView. Is this possible or do I have to completely redo my
logic?