LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to use a drop down menu in numeric control without using enum

hi,

 

I want to use adrop down menu in front panel, but i dont want to use enum as enum do not passes the exact value in the mune but passes its index.

 

is there a way to get a drop down of predefined values for numeric control..

 

for example user can only enter 200 , 400, 600, 800, or 1000 in the control. without actually typing, just cloicking on the drop down.

 

thanks

0 Kudos
Message 1 of 4
(3,452 Views)

You can use a ring.

ring.png


CLA CTAChampionI'm attending the GLA Summit!
Subscribe to the Test Automation user group: UK Test Automation Group
0 Kudos
Message 2 of 4
(3,445 Views)

Look into the ring control.  It behaves a lot like an enum, but you can dynamically set its contents and values associated with those contents.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 3 of 4
(3,441 Views)

Hey,

 

I agree with all the posts above. With an enum LabVIEW will always preassign the numeric values it uses to pass the data but using a ring we can disable this sequential preassignment in order to allocate our own values. The items in the ring will be strings which you can assign to any numeric value, by default this will be using a U16 representation.

 

Do let us know if this is not the functionality you were intending.

 

Thanks,

Aaron. E
Product Performance Engineer
Dyson
0 Kudos
Message 4 of 4
(3,437 Views)