LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Update combobox from cluster array

I am looking to update a combo box from a cluster array. The array is indexed then unbundled by name and the element I want for the combo box is selected. How would i update the combo box from here or is this method even the right method of doing it?

----------------------------------------------------------------------------------
I have not lost my mind, it's backed up on a disk somewhere
0 Kudos
Message 1 of 12
(3,255 Views)

Use the property Strings [] to populate the drop down with the items you want.  Use a local variable, or property node Value to set the selected item of the combo box.

 

Does that answer your question?

0 Kudos
Message 2 of 12
(3,238 Views)

Hey,

 

you could use a local variable to write the value to the Control or use the property node -> value.

 

Regards,

CMW

0 Kudos
Message 3 of 12
(3,234 Views)

I was too slow :-).

0 Kudos
Message 4 of 12
(3,232 Views)

This is what I have where will I link the local variable to? 

Is it possible to index out the combo box selection?

----------------------------------------------------------------------------------
I have not lost my mind, it's backed up on a disk somewhere
0 Kudos
Message 5 of 12
(3,228 Views)

You are close.  So instead of indexing on item out, why not grab all of them?  So for all items, index out all Types and then write that.  Do this with a For Loop.  Remove the index function, remove the build array, and instead put a for loop so that you index out all types (but the unbundle in the for loop) and the output will be an array of items which you set the Strings[] to.

Message 6 of 12
(3,209 Views)

Hey,

here some additional information of the two possible ways discussed in the previous posts.

..sorry for not posting an VI snippet

 

Regards,

CMW

Message 7 of 12
(3,202 Views)

If I use the cluster to array function on either example I get the polymorphic tunnel cannot accept this data type error

----------------------------------------------------------------------------------
I have not lost my mind, it's backed up on a disk somewhere
0 Kudos
Message 8 of 12
(3,190 Views)

Cluster to Array only works when the datatype of the cluser elements are all the same.  Here is what I was trying to say.  And by the way I sure hope your massive cluster is type def'ed.

Message 9 of 12
(3,175 Views)

Datatypes in arrays must have the same datatypes. e.g. strings, ..

Regards

CMW

0 Kudos
Message 10 of 12
(3,172 Views)