01-21-2016 02:03 PM
01-21-2016 02:07 PM - edited 01-21-2016 02:09 PM
The only menu-bar properties that are accessible through the VI server are "Front Panel Window: Show Menu Bar" and "Run-Time Menu Path".
Why do you need to access through the VI server? You should pass the menu bar reference through to wherever you need it. If you have the Vi reference there already, then you should pass the menu reference the same way.
I usually structure my class data for my user interface to include a VI reference and menu bar reference. That reference gets set when the interface loads and is then accessible in my data cluster elsewhere.
Cheers
--------, Unofficial Forum Rules and Guidelines ,--------
'--- >The shortest distance between two nodes is a straight wire> ---'
01-21-2016 02:14 PM
Why do you need the Front Panel Menu bar for a VI running on an operating system that doesn't use Front Panels? Perhaps you're going about something the wrong way.
01-21-2016 02:16 PM
@jcarmody wrote:
Why do you need the Front Panel Menu bar for a VI running on an operating system that doesn't use Front Panels? Perhaps you're going about something the wrong way.
Oops, good point. I read it as "run-time", so maybe that's what OP meant.
Cheers
--------, Unofficial Forum Rules and Guidelines ,--------
'--- >The shortest distance between two nodes is a straight wire> ---'
01-21-2016 02:36 PM
I wanted to obtain the reference in any other way, because I use the "Open VI Reference" and not pass the reference to the subVI. I simply wanted to know if there was any alternative to obtain the reference from the Real-Time menu. Thank.
01-21-2016 02:39 PM - edited 01-21-2016 02:39 PM
Nope. And you keep saying "real-time", but you mean "run-time", right?
Seems like something that should be possible though. Maybe submit a post to the LabVIEW Idea Exchange
Cheers
--------, Unofficial Forum Rules and Guidelines ,--------
'--- >The shortest distance between two nodes is a straight wire> ---'
01-21-2016 02:43 PM
07-13-2016 10:01 AM
I'm looking for the answer as well. For regression testing (and I'm stuck on LabVIEW 7.1 due to progam baseline), I need to be able to remotely select a menu option. So I need to find the MenuBar reference programatically.
07-13-2016 12:00 PM
Well there is a private method on the VI for Invoke Built In Menu Item, but it also says Not Implemented in 2015, not sure if it actually works or not. I also suggest Idea Exchange.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
07-13-2016 12:58 PM
Hi Dina,
when there is a run-time menu you should have a state machine or a queued message handler to process the menu selections of the user.
If this is the case and you still want to "remotely" select a menu option all you need to do is put another mesaage in your message handler (or call for a certain state).
With the right VI architecture it is simple to include remote control options…