The resource i use makes use of an index per item.
So the child item just get's an entry to that ParentID.. simple.

FUNCTION main REDIM node(number) AS STRING Node (0) = "-1|root_text" ' -1= no parent Node (1) = "0| text" ' node (0) is parent Node(2) = "1|child1 " ' first child of node(1) Node(3) = "1|child2 " ' next child of node(1), sibling of node(2) Node(4) = "0|Next level one item" Node (5) = "4|First child of node (4) ... Node(n) = "-1|Second root item" .... CALL InsertArrayOfStringsIntoTreeViewControl (hTv, Node())
"Root" "Item1" "parent1" "Item1" "Item2" "Item3" "Item4" "parent2" "Item1" "Item2" "Item2"
"Root.Parent1.Item1" "Root.Parent1.Item2"
We process personal data about users of our site, through the use of cookies and other technologies, to deliver our services, and to analyze site activity. For additional details, refer to our Privacy Policy.
By clicking "I AGREE" below, you agree to our Privacy Policy and our personal data processing and cookie practices as described therein. You also acknowledge that this forum may be hosted outside your country and you consent to the collection, storage, and processing of your data in the country where this forum is hosted.
Leave a comment: