LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I save the all the values of a tree control ?

I have a problem, in run time, I adds new items on a tree control, but i don´t know how I can save the values of the child text of each item in a file.

Thanks.
0 Kudos
Message 1 of 2
(3,811 Views)
I'm no expert on the tree control, but I made a small example to save all items to a textfile, including item tag, item string, and indent level. One drawback of this method is that it fully expands the tree regardless how the user left it. To go the other direction, you'd have to write a routine to go through the text file and programmatically build the tree.

To master the tree control, I think you have to resort to creating a control reference for it and using the Invoke Node to do some operations. For another approach to traversing and operating on a tree, check out the "Traversing Tree Controls and Setting Custom Symbols" (search the NI Developer Zone site).

Best of luck,
John
Message 2 of 2
(3,793 Views)