11-12-2015 03:02 AM
Hi. I intend to get the names of controls and indicators of a VI in a program. How do I get? Please help!
11-12-2015 03:07 AM
You can get most control names using attached snippet. You need to expand this further if you have clusters or tab controls.
Deceased.
11-12-2015 04:12 AM
Hi deceased. Thanks !
How do i differentiate between controls and indicators now?
11-12-2015 04:29 AM
Expand out the CTL property node in the loop and add the "Indicator" property.
If you wire that out of the loop you will have an array of booleans that corresponds to the array of control names.
Those set T are indicators, those set F are controls.
Deceased
06-27-2019 01:50 PM
Question: how does LabVIEW determine the order for those controls?
It's definitely not alphabetical
06-27-2019 02:12 PM
I don't remember if it is Z-order, the order of their creation, or perhaps some underlying reference number.
Does it matter?
You can test Z-order by running it once, then try reordering the controls by picking 1 or 2 and selecting Send to Front or Send to Back. Run the code again and see if the order changed.
06-27-2019 02:38 PM
If you read the help for the Controls[] property it states that the array contains the references in tabbing order. I believe that the tabbing order will default to order of creation but you can change tabbing order if you want.