05-14-2013 08:45 AM - edited 05-14-2013 08:48 AM
Hello,
I have created a simple subVI (attached), what I would like to use whenever I need to enable or disable states of any TAB control.
However I can see there is a coercing dot when I connect a reference to the TABcontrol refnum input terminal. I am not familiar with labview classes, could someone give me a brief explanation, and tell me, is this a problem, or not? And how I can do a proper reference pass into a subVI.
(I do not have such a problem if I just use directly created property nodes on the top VI, however, I like to hide such a elements into subVIs)
Thanks!
Solved! Go to Solution.
05-14-2013 08:48 AM
Please post your code in 2011 version
05-14-2013 08:51 AM
here it is
05-14-2013 08:59 AM
Right click the Tab control refnum and Enable the Include data type. I don't have a good explanation for this.
05-14-2013 09:08 AM - edited 05-14-2013 09:14 AM
If I enable the Include data type, the wire between the TAB (I use two different TAB controls in my main VI with this subVI) reference, and the subVI input terminal gets broken. If I check it with help, I get this info:
Strange, because I made a test VI to reproduce this behaviour, with only including one TAB control. With this test VI, your solution works.
Can be the problem that, I try to set the state of two different TAB controls? And one of them is inside the other?
05-14-2013 09:20 AM
I try to reproduce the problem, but even if I put 3 TAB controls into each other, the solution works.
But it gives me class conflict in my main project VI.... 😞
05-14-2013 09:27 AM
Attach the VI or VI's that show the problem.
What you attached earlier doesn't show a problem, nor a coercion dot. Your image in your first post doesn't show a coercion dot either.
05-14-2013 09:36 AM
Have I even mentioned that I avoid Tabs. (Yes, often! that was a rhetorical question)
We call them "Tab Controls" and they have a value BUT, they are containers. like panes and panels. (they have values too.)
Tabs have some uses. but they have a few challenges they inherit from the OS too.
05-14-2013 09:57 AM
Hello,
I am not in the lab anymore, I will try to extract the problematic part from my main VI, and I will post it here tomorrow.
Regards,
05-15-2013 01:29 AM
Tab controls are similar to enums (e.g. if you wire them to a case selector, you can create cases for each tab), so each tab control is different in exact type. Your subVI is for a generic tab control, not a specific instance.
You can safely ignore the coercion dot, it just alerts you to that fact.
(Similarly, if you wire two different tab terminals to an equal funcion, you get a coercion dot on each input.)