08-27-2013 12:08 PM
Hi, I have a VI containing multiple graphs (on a page of a tab control, to be precise) like these:
Now, I'd like when the VI starts to initialize all of these graphs in the same manner:
Basically, removing all the plot names and making them all not visible.
Later, as my VI executes, I want to populate each graph with its relevant data and decide programatially on the number of plots in each graph, on the names of the plots etc.
Now, it is OK to do it like above when one has a few graphs, but I am going to have some 16 of them and it is a real pain to add the wires as in the above screenshot every time I decide to add a graph to the front panel or if I decide some additional initialization is needed.
Can this be done in some sort of a loop? I visialize some sort of loop going thru all the graphs belonging to some LabView object and somehow setting all those properties, while retaining the ability to reference each individual graph later in the program (by it name).
Thanks in advance for your help.
Solved! Go to Solution.
08-27-2013 12:13 PM
Create an array of references for each of those graphs. Unlink the property notes from the graph and feed it the array of references from outside the loop. Now the loop will autoindex over the array and setting the properties on each of those graph references.
08-27-2013 12:23 PM
Great! It works and so simple.
Thanks a lot!