Hierarchical Data, Recursion, Tree-View, and a another Great Custom Class (1 Viewer)

MajP

You've got your good things, and you've got mine.
Local time
Today, 07:23
Joined
May 21, 2018
Messages
3,180
@Gasman and @isladogs.
Neither recommendation would be relevant here because it is using the tree position of the nodes as a means to establish a sort order. The Tree allows drag and drop and the ability to move nodes up and down within a level. In order to maintain that defined sort the tree view has an index property. If you read a fully expanded tree from the top down, the indices are defined in that order regardless of their level The code uses the tree node order not any kind of query sorting. It then saves this order to the table on close. This way when you reload the tree it maintains the desired order.
Node '1
----- Node '2
------------Node '3
----- Node '4
Node '5
In this class we also added a feature to Auto Outline. It thens adds the outline numbering once you move things up and down in the tree. But the sort and the numbering are somewhat independent.
 
Last edited:

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Top Bottom