I am building a dynamic tree box based on a directory structure.....so I don't know in advance how many roots and nodes there will be in the tree. The final nodes of the tree could have the same name. I then put the tree into an application.
When a user clicks on a node I want to re-create the 'Path' from that node back to the root.
So if someone selects say 'Ducato' I want to be returned 'Trucks - Fiat - Ducato' Similarly if you picked a node that was not the final leaf it would also work. For example selecting 'Audi' would return 'Cars - Audi'

I can get a list of roots or the text of the item selected
show((myDirTree << Get Selected) << getLabel);
show((myDirTree << getRoots) << getLabel);
And I can run a script when a selection is made.
myTree << setNodeSelectScript(
show((myTree << Get Selected) << getLabel);
show((myTree << Get Roots) << getLabel)
);
But I do not know how to get the 'path' back to the root each node takes........
Cheers, Troy
You can 'walk back' using the Parent message to the current display box.
See Help > Scripting Guide:
