I have a TreeView control in my WinForms .NET application that has multiple levels of childnodes that have childnodes with more childnodes, with no defined depth. When a use
you need a recursive function to do this [or a loop equivalent, but the recursive version is simpler] - pseudocode:
function outputNodes(Node root) writeln(root.Text) foreach(Node n in root.ChildNodes) outputNodes(n) end end