LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Setting Control Values in a cluster

I am aware of the technique to set a control value on another VI's FP using an invoke node and Flatten To String Function, but is there any way to set a value of a control inside a cluster?

Many thanks to anyone who may be able to help.
0 Kudos
Message 1 of 4
(3,202 Views)
Hi Dan,
a cluster has a property called Controls[], this returns an array of references of all the cluster elements. You can use each reference to set the element value with the property Value.
I attach a simple vi that shows it.
Good luck,

Alberto Locatelli
Message 2 of 4
(3,202 Views)
Thanks Alberto, thats great. Looking back I probably didn't make myself very clear, but how do you do what you have done in your example but to update a cluster in another currently running VI? I presume you need to use control references/refnums but don't really have a good understanding of these yet.

Any suggestions? thanks for your help,

Dan
0 Kudos
Message 3 of 4
(3,202 Views)
Hi Dan,

Definitely! You have to pass to the sub-vi the cluster reference.
See the attached example,

Alberto
0 Kudos
Message 4 of 4
(3,202 Views)