LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Saves files in dev mode but not in exe - NOT WHAT YOU THINK

Solved!
Go to solution

Hi,

 

I've written an untility that will go through all VI and CTL files in a directory and write / update the description of all of the files. This works great to add copyright information and company information, etc.  The program runs fine and updates all target files when it runs in the development mode. If I've built it into an exe though everything appears to work, but it doesn't. I've put indicators on the "Warnings" output and the "Get VI Version" (see the attached code); there are no warnings, the vi versions are correct, and the path to save to is correct, unfortunately the updated files are not saved.

 

Attached is a simplified version of the code at the heart of the matter.  This has a calling VI that sends in an array of files to be updated, the top one is "popped" off and processed (there is a LOT more that gets added into the description than what is shown here, but that all works fine as the string out shows the proper updated description), and then the process checks what LV version the file being updated is and saves it to the proper version.  As I said this all works perfectly when run as a VI, but when I compile it to an exe, although it appears to work, the new, updated files are not saved.

 

The attached file is in LV 2014.

 

Any ideas?

 

Thanks,

Dan

 

0 Kudos
Message 1 of 3
(2,529 Views)
Solution
Accepted by topic author m3rl3n

An executable runs in the Run Time Engine.  The RTE does not have the capability of saving a VI.  The only thing here that I would say does not make sense is that the Save VI should thow an error stating that it does not work in an executable.


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 2 of 3
(2,523 Views)

That's what I was afraid of.  Bummer.  

 

I do agree, the save vi method should throw an error if it used in an exe.

 

It sure would have been nice to distribute the program as an exe though.

 

Thanks for the answer.

 

Dan

 

0 Kudos
Message 3 of 3
(2,517 Views)