01-19-2015 05:21 AM
I have a labview executable which uses some resources.Currently I'm using the resources by giving file path.It becomes a problem when uploaded the executable and support files in the Internet and accessed from there.It loads only exe file and misses resource file.
Is there any option to embed resource files inside executable ?
Solved! Go to Solution.
01-19-2015 06:56 AM - edited 01-19-2015 06:58 AM
If they are not LabVIEW VIs - e.g. documents, external code (dlls) then no, I don't think they can be included 'inside' the executable. In your build specification you can set them to 'always include' and then in the destinations page select where they end up (e.g. in the same directory as the .exe, in a support directory etc.).
If you use the 'application directory' VI in the File I/O palette - this will return the path to either the project if in the development environment or the folder of the executable in the runtime engine. This should allow you to specify the path that will work whether in the runtime engine or development system. You can use conditional disable structures or the App.Kind property to determine if the VI is running in the dev suite or the runtime engine.
Also, the paths will only work on the local (or network) file system - you can't specify an internet address - LabVIEW won't be able to download the files from the internet unless you program your application to do that.
You should put the executable (build specification output that includes the .exe and your supporting resources) in a .zip file if you are uploading to the internet or create an installer.
01-19-2015 10:40 AM
Sounds to me like you need to build an installer that can then include the resources you need.
01-20-2015 02:08 AM
From Sam_Sharp's reply I have realized that labview will not download the support file from internet unless programmed to do that.I think my problem will be resolved if added a program to fetch support file from internet or network location and keep with executable.
I'm fairly new to labview and hence it will be highly appreciable if any one could help me out to understand how the programming for downloading could be done.