LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to write array of values to cluster of indicators(tank sliders)??

Solved!
Go to solution

I am trying to write a 1-D array of values to thier corresponding 8 tank sliders.

So each element of the array will be displayed as the value of the slider.

 

How can I do this?

It works if you display it to a cluster of numeric values, but not the sliders.

I also tried writing the array to the "value" property  of the each of the sliders, but still doesn't seem to work.

 

Any suggestions?

0 Kudos
Message 1 of 6
(3,038 Views)

Post your VI so we can see how it is structured and what you are trying to do.

 

It sounds like you need to use Index Array on your 1-D array, expand it downwards to get multiple outputs and wire each output to one of your tank indicators.

 

If it is a cluster of tank indicators, use the Array to Cluster function (right click to set the number of elements), then wire that.

0 Kudos
Message 2 of 6
(3,028 Views)

 Here is my code,

so I basically want to write the values of the table (each row) to 8 sliders.

For now I just want row 1 to be displayed on the 8 sliders.

 

I tried using the array to clusters, but I can't seem to get it working...

 

Thanks!!

0 Kudos
Message 3 of 6
(3,024 Views)
Solution
Accepted by topic author developer001

001,

 

How did you create those sliders? They are actaully clusters of two elements, both of which appear to be identical sliders sitting on top of each other.

 

That is probably why you are having so much trouble wiring your data to them.  I suggest that you create a new cluster with standard sliders.  Then you can use the Array to Cluster primitive to move the data.

 

Two cautions: 1. The Array to Cluster defaults to 9 elements in the cluster regardless of the number of elements in the array.  Pop up on the cluster output terminal to change the number of elements if needed.

2. You apparently added items to the cluster out of order.  The cluster order is important if you want to get the data to the right places.

 

Also, it would be much easier for us to test your code if you included some data in 2D Array Input.  Put the data in there then Edit >> Make Current Values Default. Then save.

 

Lynn

0 Kudos
Message 4 of 6
(3,007 Views)

i think you want to make a 1d array of sliders to match your graph...

get row from 2d array (1)_BD.pngget row from 2d array (1)_FP.png

and i think you want to represent your 2d array with your sliders as oppose to your cluster of 2 element cluster...

get row from 2d array (1)_FP.png

0 Kudos
Message 5 of 6
(2,986 Views)

Thanks! I have no idea how I ended up creating the sliders like that, I figured it shouldn't be this complicated!!

 

But it works perfectly now!Smiley Happy 

0 Kudos
Message 6 of 6
(2,948 Views)