You can see if you trace the flow of the function through. It can be difficult at times, but you must be able to do this to fully understand recursion. See, the factorial function was called six times. You just keep working up the chain. I hope you are still with me.
Recursion is a tricky subject, but an important and powerful one.
I will now show how to recurse through ALL the children in a TreeView structure. A TreeView Control is a hierarchy. There are an undetermined number of levels in the hierarchy, and each node in the hierarchy can have zero or more children on the next lower level of the hierarchy. Wend end if 'Here is where you will want to put whatever processing you want done 'on each and every node. This function is called by passing in the Key of the node that you want to start at.