10-06-2017 09:44 AM
I have a main VI with a radio button control on the front panel. I has the property of No Selection allowed.
I am passing a reference of that radio button control to the subVI.
Within that subVI I am trying to update that radio button control's Value (signaling) to No Selection, but LabVIEW is setting an error. If I changed to just Value, I am still getting an error.
I am not sure what I am doing wrong.
10-06-2017 09:59 AM
What error is it setting and where?!!
10-06-2017 09:59 AM
Well, what does the error say???
Can you show us some simplified code. There are millions of ways to do it wrong and maybe a dozen ways to do it right, so don't keep us guessing. Without more information, we cannot narrow it down for you.
10-06-2017 10:56 AM
"allow no selection" can only be changed when in edit mode.
If you require the ability to switch at run time you will have to use a cluster of Booleans or such and then implement your own mutual-exclusive logic behind the scenes.
Ben
10-06-2017 11:22 AM
@Ben wrote:
"allow no selection" can only be changed when in edit mode.
I think he's talking about a value of "no selection", assuming that the radio control is set to allow it.
Do other selections work without error?
10-06-2017 11:30 AM - edited 10-06-2017 11:31 AM
@altenbach wrote:
@Ben wrote:
"allow no selection" can only be changed when in edit mode.
I think he's talking about a value of "no selection", assuming that the radio control is set to allow it.
Do other selections work without error?
If that is the case, then the control of the sub-VI needs to be modified to match the control when it is set for "allow no selection". That can be as easy as ctrl-dragging a copy of the radio control into the ctrl of the sub-VI.
Ben
10-06-2017 11:37 AM
We clearly need to see the code. It is possible that the subVI was created (e.g. "from selection") before the the "allow no selection" permission of the control was changed, meaning that the reference input has the wrong type. But that would break the reference wire. We really don't know what is meant by "setting an error". Too ambiguous.
10-06-2017 11:42 AM
I have used references before, and they have always worked.
I have decided not to deal with this convoluted code that I have inherited.
Updating the main VIs front panel control which in turn causes the subVI to run again.
Argh.
Thanks for all the input.
10-06-2017 11:53 AM
njacacia wrote:I have decided not to deal with this convoluted code that I have inherited.
We still would like to know if there is maybe a bug (as it almost seemed from reading the first posts).
10-06-2017 01:58 PM
There may have been.
In short my approach is to eliminate the need for the references.