LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

help with path and exe

Hey all I have a question about building an exe. I have a main application that is going to be built into an exe within this main app I have a couple of subvi's that need a file that I have my limits set up in. what is the correct way to get the right path to the file. these limit files will be added to the build as source files or any reccommended better way. I have never really used the application builder before and now that I have LV 8.0 it is even more different. So what is the correct way. Attached is the subvi for you to look at. It is in LV 8



Joe.
"NOTHING IS EVER EASY"
0 Kudos
Message 1 of 15
(4,954 Views)
I didn't get a chance to open you VI, but hopefully this can answer your question.
 
The default behavior for all VIs in a built application is to get built into the executable. If you have a data file, and you add the data file to your build, it will default to a data folder under your target output directory. So let's say my output directory is as follows:
 
My Documents\Application\Application.exe
My Documents\Application\data\My Limits.xls
 
If your subVI is trying to programmatically find this file, it needs to contain code that takes the current VI path (My Documents\Application\Application.exe\mySubVI.vi) and then go up two directories and down into data and look for the file there.
 
So that basically equates to two strip paths and a build path to your limits data file.
 
You are correct in your assumption that you need to add your data files as source files to your build.
Message 2 of 15
(4,938 Views)
Thank you Jayson that solved the problem. another question though.
 
When I build an exe and an installer what files do i need to put on the cd for distribution.
do i need to put both on the cd or just the installer. Please advise
 
thanks for your help



Joe.
"NOTHING IS EVER EASY"
0 Kudos
Message 3 of 15
(4,924 Views)
When you create an installer and add the build specification to it, the output of the installer is all you care about. Just put the output of the installer onto the CD. It made a clone of your application.
Message 4 of 15
(4,922 Views)

Where in the installer do I add these specifications and also if i tell it to include other installers does the installer when run on another machine look to see if it already has the products installed.

Say for instance I tell the installer to include daqmx 8.0 and MAX 4.0 does the installer look to see if the computer already has these components installed or does it just install over top of the others.




Joe.
"NOTHING IS EVER EASY"
0 Kudos
Message 5 of 15
(4,915 Views)
On the Installer, in the Source Files page, there is a list of Build Specifications. All of the builds that you created will show up under this node. Just add it by clicking on the "->" button.
 
As far as the other installers go, if the machine already has the same/newer version of the installer, it won't run. If it has an old version of the software, then it will uninstall that and then install the new version.
0 Kudos
Message 6 of 15
(4,911 Views)
Ok I did that and now when I tell the installer to build and tell it to include daqmx 8 it starts to build and then tells me that there is an error that it cannot find daqmx 8.0



Joe.
"NOTHING IS EVER EASY"
0 Kudos
Message 7 of 15
(4,907 Views)
That's not my area of expertise, but it looks to me like you don't have a full install of DAQmx 8.0?
0 Kudos
Message 8 of 15
(4,901 Views)

"That's not my area of expertise,..."

as is the case with me. "Phar Lap" is the OS used by RT nodes.

LV8 RT has not been released yet. I also believe the FP in LV8 is not ready for prime time. What is your intended target of the exe?

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 9 of 15
(4,893 Views)

My intended target is just another PC running win2k or higher with a daq card in it for my program. nothing fancy.

another thing is that if I tell it not to include daqmx and try to build it, it comes up and prompts me for an *.id file for daqmx and I found this in the file where I unzipped the downloaded file and it built fine but I have not run it on another machine just yet.

thanks for the help




Joe.
"NOTHING IS EVER EASY"
0 Kudos
Message 10 of 15
(4,889 Views)