JustJay Posted October 29, 2005 Report Share Posted October 29, 2005 I have written a very simple vi that uses a number variable to call various text files into a text string. It works well in the design mode. When I build my app, I include these text files, and upon install, it places them in the install directory/data/ just as I asked it to do in the app builder. When I run my app, it cannot find the text files. In the design mode, I had all my text files in a directory on my hard drive, and they were called from there. What do I do so that my vi knows to search in the \wherever\data directory after install? Thanks for your help! Jay Quote Link to comment
didierj Posted October 31, 2005 Report Share Posted October 31, 2005 If you use "Current VI's Path" then take in account that the returned path in an exectuable is of this way: <installation dir>\<executable>.exe\<vi-name>.vi So in the dev-env you use one "strip path" to get the directory, but in the executable you'll need TWO "strip path"... Quote Link to comment
JustJay Posted October 31, 2005 Author Report Share Posted October 31, 2005 If you use "Current VI's Path" then take in account that the returned path in an exectuable is of this way:<installation dir>\<executable>.exe\<vi-name>.vi So in the dev-env you use one "strip path" to get the directory, but in the executable you'll need TWO "strip path"... I will give that a try this evening.... Thanks Quote Link to comment
WMassey Posted October 31, 2005 Report Share Posted October 31, 2005 The attached VI shows one method of finding the containing folder regardless of where the VI is stored. It may be in a folder, LLB or EXE and if it is either of the latter two, then the folder containing the LLB or EXE is returned. Download File:post-2800-1130792964.zip Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.