LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

extra folder added into the current vi's path function when compiled into executable

Solved!
Go to solution

Good to know, thanks!

Looked a bit further, and it seems LV2013 autochecked "Use 8.x file layout" when opening the LV 8.6 project.

LV 2015 did not.

So this explains why I got different results.

/David

0 Kudos
Message 11 of 13
(662 Views)

@TegtmeierD: I realize this is an old thread, but hope you're still subscribed, because I have exactly the same problem but it is not clear how you used the Application Directory function to resolve the extra folder issue.


TegtmeierD wrote:..." use the "Application Directory" function and it does resolve this issue.

This is what I found:

Using Application Directory vi at development time gives you: c:\lvproj-folder
Using Application Directory vi at runtime time gives you: C:\exe-install-folder
However (and this is my point of question) to actually access the sub folder at run time (inside the exe) would need to be:

C:\exe-install-folder\application.exe\subfolder
NOT following: C:\exe-install-folder\subfolder

 

Are you programmatically inserting the "application.exe" name into the path?

^TeraTech.

CAUTION! New LabVIEW adopters -- it's too late for me, but you *can* save yourself. The new subscription policy for LabVIEW puts NI's hand in your wallet for the rest of your working life. Are you sure you're *that* dedicated to LabVIEW? (Check out this lengthy post of mostly complaints)
0 Kudos
Message 12 of 13
(351 Views)

@TeraTech wrote:

@TegtmeierD: I realize this is an old thread, but hope you're still subscribed, because I have exactly the same problem but it is not clear how you used the Application Directory function to resolve the extra folder issue.


TegtmeierD wrote:..." use the "Application Directory" function and it does resolve this issue.

This is what I found:

Using Application Directory vi at development time gives you: c:\lvproj-folder
Using Application Directory vi at runtime time gives you: C:\exe-install-folder
However (and this is my point of question) to actually access the sub folder at run time (inside the exe) would need to be:

C:\exe-install-folder\application.exe\subfolder
NOT following: C:\exe-install-folder\subfolder

 

Are you programmatically inserting the "application.exe" name into the path?


This is one of the reasons I always say to use Application Directory to find something outside of the executable (config files, data files, etc) and use Current VI Path to find something inside of the executable (almost always other VIs).


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
Message 13 of 13
(339 Views)