I would like to create a tabcontrol with cluster of controls on the page and each time that I add a new page the same cluster of control should appear. These clusters should be the elements of an array that permits me to manipulate easily.
Do someone know how to do it.
thanks by advance
Solved! Go to Solution.
You will get the Duplicate Page method option if you have enabled the VI scripting, with this you can have whatever controls in one page gets duplicated. Then depending on the number of Tabs you can handle the cluster into an array.
Thanks but dynamically how can I do to create a new page with all the control ? I cannot see the Duplicate in the Invoke node
If you are using LV2011 you have the direct option to Enable the VI scripting Tools>>Option>>VI Server. Enable the VI scripting option and check.
Note that you cannot do this while your program is running. If you want to dynamically create another page with the same set of controls at run-time, you are probably better off using the same controls over again, using some sort of listbox or combobox to select the set of interest. Use an array on a shift register to cache the data for each instance of the controls. When the selection changes, update the currently selected instance in the shift register, then populate the controls with the new values. This ends up being a lot less code than the tab control, and scales a lot better than a tab control.
If you want to dynamically change what the controls are, use subpanels and host VIs in them.
Let us know if you need more info.
could you givem an example to what you said : "Use an array on a shift register to cache the data for each instance of the controls. When the selection changes, update the currently selected instance in the shift register, then populate the controls with the new values"
because I really do not know how to do it.
thanks by advance
Here you go.