LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

enumerate video modes to combo box

Solved!
Go to solution

Hello folks,

 

I noticed the potentially handy IMAQdx Enumerate Video Modes vi.  I'd like to use that to dynamically fill in a ring menu / combo box (whichever would be appropriate, though I think it is supposed to be a ring menu so that the output is U32, which is the input from of the IMAQdx "VideoMode" property) so that I can hook in a different USB camera and not have to fill in all the modes again manually.  I have tried to understand what a typedef is and how to make the output from the Enumerate vi work with that property node, but with no success.  Pictures detailing my current vi and the data type mismatch are below.

 

zob

 

 

 

MY VI:

video modes to combo box

COMPARISON OF DATA TYPES:

type comparison

 

0 Kudos
Message 1 of 5
(3,198 Views)
Solution
Accepted by topic author zobfish

The order of the elements in the cluster matters.  In one case, you have the numeric first, in the other you have the string first.

 

You need to go through your array and rebundle those elemetns into the correct order.

0 Kudos
Message 2 of 5
(3,189 Views)

That worked, thank you my good sir.  For those who come after, here is the working solution.  If there's a better way, I'd be interested to hear about that, too.

 

solution

0 Kudos
Message 3 of 5
(3,180 Views)

You can do without the index array at the front of the loop and the build array at the end of the loop.  Just make your tunnels for the cluster arrays coming in and going out into auto-indexing tunnels.  When you do that, you won't need to wire the array size into the N of the For Loop either.

0 Kudos
Message 4 of 5
(3,174 Views)

Beautiful, I can always appreciate simplification.  Thanks again!

 

Again, for the sake of those who see this later, here is the simplified loop:

 

solution2

0 Kudos
Message 5 of 5
(3,171 Views)