LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

get element in combo box indicator

a vi generates an array of strings, how can I select one element with a combo box and send it to another vi as if it is a control?

thanks

0 Kudos
Message 1 of 15
(5,040 Views)
hope this helps:
Harold Timmis
htimmis@fit.edu
Orlando,Fl
*Kudos always welcome:)
Download All
0 Kudos
Message 2 of 15
(5,031 Views)

Thank you but It's not what i meant, my fault

A vi generates this array of strings, as I said, so I had to fill the combobox programmatically, that mean at run time. Then another vi should be able to get the element selected by the user from front panel and do something with it.

For the first vi the combobox is an indicator, for the second a control.

Hope this will clarify,

thank you again

 

Diego

0 Kudos
Message 3 of 15
(5,005 Views)
Can't you just pass the same array of strings to the subvi and fill the combobox with the same values as the indicator in the main VI?
0 Kudos
Message 4 of 15
(5,001 Views)
it doesn't let me pass an array of strings to the combobox,it accepts only string
0 Kudos
Message 5 of 15
(4,995 Views)

You can add an array of strings to the 'Strings[]' property.

 

combobox.png

0 Kudos
Message 6 of 15
(4,992 Views)
the string property of a control is a source, not a sink! how can you make it a sink? i have the black arrow on the right, not on le left as you
0 Kudos
Message 7 of 15
(4,985 Views)
Right-click on it and select 'Change all to write'.
0 Kudos
Message 8 of 15
(4,983 Views)

You can also right-click the combobox and select: Create\Property Node\Strings[]

That way you don't need a reference to the combo box 🙂

 

SNAG-029.jpg

0 Kudos
Message 9 of 15
(4,975 Views)
That's how I had it, but the snippet tools converted it to a reference.  That's what I get for trying to be too fancy.
0 Kudos
Message 10 of 15
(4,973 Views)