01-13-2015 02:04 AM
Hi,
I wanna identify type of each control from front panel of a main VI. When a control is type "tabcontrol" I will determine all contained controls of each tab.
I changed to LabVIEW 2013 for a short time. Unfortunately in LabVIEW 2013 I didn't find a property to identify the type of a control. A condensed code with my problem you can find in attachment.
Can anybody tells me, how I can solve this in LabVIEW 2013? Thank you in advance.
Christian
01-13-2015 03:29 AM
01-13-2015 07:12 AM
Here's a VI I write a while ago that gets a reference to all controls and indicators. What I did for detecting the tab control is to cast the reference to the PageSelector class. If there was an error, you have a normal control. Otherwise you can perform your recursive operation.
01-13-2015 07:26 AM
Hi crossrulz,
thank you for your help. Have you got this VI also in version 2013?
Christian
01-13-2015 08:57 AM
C.D. wrote: Have you got this VI also in version 2013?
Here you go.
01-13-2015 10:14 AM
There's also a VI that ships with LabVIEW that does this:
LabVIEW [20xx]\vi.lib\Utility\traverseref.llb\TRef Get All FP References.vi
It has various inputs that let you decide what kinds of objects you want to dig into, whether you want to include decorations, etc.
P.S. - I discuss this VI (and many, many others) in my Hidden Gems in vi.lib presentation.