05-26-2010 02:08 PM
I'm able to save the structure and data to a text file, thanks to the "save tree structure to textfile" info found on this msg board, but can't seem to load the complete tree structure data from the text file into another tree. I've only been able to load parent data but can't get the hierarchy of the tree with the indents and child data to work.
Thanks
05-27-2010 05:37 PM
Hi Rick2045,
Could you post a link to the example or discussion thread that helped you save the data? Could you also post what you've tried so far?
Thanks!
Regards,
05-28-2010 08:52 AM
Hi Tanya,
I've solved part of my initial problem(see attached)...
Now the fun part!!!...How do you save/load (from textfile) multiple columns of a tree structure as shown in the jpg?
http://forums.ni.com/ni/attachments/ni/170/228320/1/tree%20pic.jpg
Thanks
Rick
05-28-2010 12:40 PM
Hi Rick,
Have you seen this community example: Programmatically Populate a Tree Control ? It shows how to use property nodes to populate a tree control.
How to get the data from your text file and write it to the property nodes would depend on how your data is organized in the file.
Hope this helps!
06-02-2010 02:12 PM
Thanks Tanya,
However, I'm still stumped on how to copy (from text file) to other columns in the tree (from one tree to another). I can only get the first column to load.
I've attached my working VI and a textfile that I use to load into the "User list" tree.
Rick
06-03-2010 11:01 AM
I solved the problem!!..Perseverance payed off!!
All that was required was to take the remaining data from the other columns (which was saved to text file) out of the Index Array and Build Array (each column as inputs) and connect the output to the Child Text of the Edit Tree Item. Add Item to End.
Works like a charm...can save tree structure "tree" to text file (including columns) and load to another tree "User List"