Jump to content
Sign in to follow this  
Eugen Graf

Get Path to the Frontmost VI

Recommended Posts

Hello, can anybody help. I want to get the path to the frontmost VI if mouse was doubleclicked. Probably my solution will work with an EXE, but it don't work while programming.

Eugen

Share this post


Link to post
Share on other sites

QUOTE(Eugen Graf @ Aug 16 2007, 10:25 PM)

Hello, can anybody help. I want to get the path to the frontmost VI if mouse was doubleclicked. Probably my solution will work with an EXE, but it don't work while programming.

Eugen

On a side note, AFAIK, if the VIs are in memory (which they'll have to be to be front-most :) ) you don't need a full path for the "open" command. Just a string of the VI name will do.

Why shouldn't this work while programming? I think it should. Ah. You're building the paths from your "App" instance. While programming, this is LabVIEW itself I believe. In an EXE it's your build program. I think you need to switch paths depending on whether you're running a built program or within the development environment. Or you can just get "All VIs in memory" passing only these strings to the "open" command and forget the path altogether.

Shane.

Share this post


Link to post
Share on other sites

QUOTE(Eugen Graf @ Aug 16 2007, 01:25 PM)

Hello, can anybody help. I want to get the path to the frontmost VI if mouse was doubleclicked. Probably my solution will work with an EXE, but it don't work while programming.

Eugen

Your problem might lie in the application reference. In LV8+ they changed some things over and I've been using the VI at vi.lib\Utility\allVIsInMemory.llb\Get User Application Reference.vi to get the app reference for utilities in different app instances (ie: project tools).

Share this post


Link to post
Share on other sites

In fact I want to get the reference to the double clicked control.

And NO, GetAllVIsIn Memore gives only VI Names without a full path.

Thanks, Eugen

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.