TreeView and read level

  • Thread starter Thread starter black_sun
  • Start date Start date
B

black_sun

Hi,
I have a problemand I ask your help.
I have a treeview with N levels. I want to get the name of the nodes
of the same level...that means I want in an array all the nodes at the
level0, then level 1 and so on...
Do you now how can I do this?

Thanks in advance.

Bye
BlackSun
 
A little bit difficult in my idea, because those arrays are not by
definition unique.

Cor
 
I have a treeview with N levels. I want to get the name of the nodes
of the same level...that means I want in an array all the nodes at the
level0, then level 1 and so on...

To what end?
Even assuming you can get this information, what is it going to /tell/ you?

Anyway ...

Root Nodes (Level 0) you can get easily enough. Just iterate directly
through [<treeview>].Nodes.

All the other Nodes in the tree exist only in the Nodes collection of
their immediate parent Node. There's no easy way to iterate through
/every/ Node in the tree any more (you'll probably have to hold them in
a duplicate, external collection).

Regards,
Phill W.
 
Back
Top