LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

values for menu

Hi. I need ASAP help to programmatically assign a value to each item in the
menu.

LostInPathOfLabview
0 Kudos
Message 1 of 4
(2,969 Views)
Hi,

to clearify some conventions:
a menu item has a tag and a name. I think you will set the name of a menu item tag.

You can create a menu programmatically using the functions in the "application control>>menu" palette or by editing the menu file with "Edit>>Run-Time Menu...".

With the menu functions you can set the name and shortcut of your custom item tags but you will not be able to change this for the build in item tags. You cannot change the name for the APP_OPEN tag which is for the english run time version "Open..." to a german "Öffnen...". To get this you must replace the runtime engine with that one for the desired language.

Waldemar
Waldemar

Using 7.1.1, 8.5.1, 8.6.1, 2009 on XP and RT
Don't forget to give Kudos to good answers and/or questions
0 Kudos
Message 2 of 4
(2,969 Views)
Have you looked in the Application Control pallette and the menu functions? Everything you need is in that sub-palette. If you are having problems with a specific function what is it and do you have an example you can attach

-Norm Kirchner
Engineering Specialists, Inc.
NormK@engspec.com
0 Kudos
Message 3 of 4
(2,969 Views)
Are you talking about the run-time menu or a menu ring? Either way, you could use a case to assign a value based on the selection. I think enums connected to cases are easier to use the menu rings: for enums, the case automatically gets named using the enum item strings.
If you're using a custom run-time menu, each menu item has an item name and an item tag. The item tag is a string that can be read by the Get Menu Selection function. If you use a numeric string for each tag, you can then use the Decimal String to Number function to get the value.
Look at the attached example. Copy the VI and the RTM run-time menu file to the same directory.
Download All
0 Kudos
Message 4 of 4
(2,969 Views)