LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Best way to save data within a build application

Solved!
Go to solution

LabVIEW 2010, Application Builder

 

I have finally figured out a way to find the paths of dynamically called VIs within my built application in LV2010 (now that you CANNOT use List Folder to get a list of VIs in your built application anymore).

For what it's worth, my solution (gleaned from other posts) is to use a Post-Built step that saves all the "Top Level/Always Included VIs" development paths in a text file in a "bin" subfolder of my app (in which I also store dll I need). It's not very elegant though, as anybody can take a peek at it and mess up with that file.

I could of course make it binary and give it a .dll extension to discourage people from getting close to it, but I am wondering whether I could not just simply save this info (the list of all Top Level/Always Included VIs development paths) in a the exe file itself (during the post-built step). I just don't have any idea how.

Any suggestions?

0 Kudos
Message 1 of 6
(3,213 Views)
Solution
Accepted by topic author X.

Hey,

 

I don't believe there is a more elegant solution to this problem, as I believe you are right that you can't use the List Files VI to get list because it's inside the exe itself.

 

 

Regards,
Jake G.
National Instruments
Applications Engineer
0 Kudos
Message 2 of 6
(3,173 Views)

Hi X-),

did you read this article. I think it can also work for 2010.

http://thinkinging.com/2009/10/02/how-to-list-files-in-a-labview-2009-executable-app/ 

 

Mike

Message 3 of 6
(3,160 Views)

@TheTician: Well I have made a shrewd move and created an additional "include" directory in my distributed app and set the permission of the text files to "read only". I hope that will discourage people from trashing or messing up with the files. I still wonder whether there could be a way to set some default values of one of the app's VI at the very end?

 

@Mike: no, this possibility has been removed in LV 2010.

0 Kudos
Message 4 of 6
(3,149 Views)

Hey guys,

 

I might be missing something here, but it looks like to install that library you have to agree to some terms and conditions that you may not want to do if you're building an executable to sell.

 

Jake

Regards,
Jake G.
National Instruments
Applications Engineer
Message 5 of 6
(3,136 Views)

Ah, OK, I did not look into the Open G zip library and indeed, they are using a dll to look into an archive, so maybe that bypasses the problems that the LV functions have. However I had understood that NI was aware of this not being a good safety practice to let people read into an executable and they had blocked this ability. I surmise that this means that the dll above will not be able to work on an exe anymore in 2010, but I haven't tested this. Rolf Kalbermatter, who originated the Open G zip library was quite vocal about it in this thread, so he should know better than anybody. But gain, I have not tested this myself, as I have found a workaround...

This being said, you are correct, a product using the Open G library needs to mention it. Here is the copyright blurb on Open G's VIs:

 

Please visit http://www.OpenG.org to learn about the
Open Source LabVIEW software movement.

NOTICE -- YOU MUST LEAVE THIS NOTICE IN PLACE.  PER THE TERMS OF THE LICENSE BELOW, YOU MAY SUBLICENSE THIS SOFTWARE
IN ANY WAY THAT DOES NOT CONFLICT WITH THIS LICENSE.

### BSD License (http://www.opensource.org/licenses/bsd-license.php) Begin ###
 
Copyright (C) 2002-2004 Rolf Kalbermatter rolf.kalbermatter@citeng.com
Copyright (C) 2002 Jim Kring jim@jimkring.com

All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

    * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
    * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the
       documentation and/or other materials provided with the distribution.
    * Neither the name of SciWare, James Kring, Inc., nor the names of its contributors may be used to endorse or promote products derived
       from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

### BSD License End ### 

0 Kudos
Message 6 of 6
(3,126 Views)