Hi,
I am trying to formulate a loop in catvba to basically count the children of each branch of a loaded specification tree. I know Root is level 0....and the level converges to n as the branches also have smaller branches. I want to count the children in all specification tree branches (to the level n). All I can think of right now are nested loops to the nth degree and I always end up going back to square one since the loop diverges away from the starting point of branching.
Has anyone out there done something like this? I think I am going about this the wrong way.
======================================================================
Root
|
|_catproduct
| |
| |_catpart
| |
| |_catproduct
| |
| |_catpart
| |
| |_catpart
|
|_catproduct
|
|_catpart
|
|_catproduct
|
|_catpart
|
|_catpart
=====================================================
I am trying to formulate a loop in catvba to basically count the children of each branch of a loaded specification tree. I know Root is level 0....and the level converges to n as the branches also have smaller branches. I want to count the children in all specification tree branches (to the level n). All I can think of right now are nested loops to the nth degree and I always end up going back to square one since the loop diverges away from the starting point of branching.
Has anyone out there done something like this? I think I am going about this the wrong way.
======================================================================
Root
|
|_catproduct
| |
| |_catpart
| |
| |_catproduct
| |
| |_catpart
| |
| |_catpart
|
|_catproduct
|
|_catpart
|
|_catproduct
|
|_catpart
|
|_catpart
=====================================================