LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Insert informations on cluster

Hello

I have a cluster and need to fill it programmatically
If I have 3 options a cluster should appear with the 3 options I want to insert (as in the image)

leandrofeder_0-1727799417040.png

 

But if you have 1, 5, 6, 7 options you should increase and the other options appear
The idea is to use it as a dropdown menu with options where the user selects what he wants to do

 

How can i do that?

 

0 Kudos
Message 1 of 8
(432 Views)

A cluster has a fixed number of elements at compile time, but you can hide elements. Create a cluster with the max number of elements needed, then hide some as needed.

 

Seems convoluted. Maybe a listbox would me a more reasonable solution once we know more about your use case.

0 Kudos
Message 2 of 8
(425 Views)

It's a menu of options at the top of the screen (like on a web page) where you have several options to select from
When the user selects one of them, the options for the menu should appear

Something along these lines:

leandrofeder_0-1727800995919.png

 

0 Kudos
Message 3 of 8
(410 Views)

I don't understand why you think you need a cluster for that.

 

If you already have all the program logic implemented for a cluster with a fixed number of elements (do you?), just follow my advice and make a cluster with all possible elements, Set it to "auto-sizing: arrange vertically" and make only the desired elements visible.

0 Kudos
Message 4 of 8
(406 Views)

If the example case you show is close to what you're using it for, you could use a picture ring:

 

Kyle97330_0-1727804188967.png

There are two problems with picture rings though:

1. You have to manually import all the pictures

2. You can't change the list while it runs, though you can disable some elements:

Kyle97330_1-1727804725402.png

 

Otherwise, a Cluster with the other suggestions for things may work out as you want.

0 Kudos
Message 5 of 8
(380 Views)

Here are instructions for a Hamburger Menu. I think that is what you want.

 

But you cannot add/remove elements as desired. You may have to over specify your options, then make some visible/hidden as a workaround.

0 Kudos
Message 6 of 8
(374 Views)

Can you share the country selector control?
Country dropdown with flags like this can be useful for my project.

0 Kudos
Message 7 of 8
(314 Views)

@maxnoder1995 wrote:

Can you share the country selector control?
Country dropdown with flags like this can be useful for my project.


If you're talking about the example of a picture ring I posted, I didn't save it or anything.  The process was this:

1. Add a "picture ring" control.

2. Use the Windows "snipping tool" to take a screenshot of a flag somewhere.  (Or, in some other way, get a picture of a flag into the clipboard.)

3. Right-click the picture ring and choose one of the "Import picture..." options

4. Repeat 2 and 3 until all the flags you need are there.  Probably try to get all of them from the same source to match sizes and colors.

0 Kudos
Message 8 of 8
(290 Views)