Example Code

LabVIEW - File Path Constants - Development vs. Run-Time Environment

Code and Documents

Attachment

Overview
This is a short example to highlight the difference in operation of file path constants between the development and run-time environment in LabVIEW

 


Description
When performing file operations within a distributed application the developer must take care to ensure that the application is robust to changes in OS, and that all files can be referenced accordingly. There are several file path constants which are used as part of this process.

 


Requirements

  • LabVIEW 2012 (or compatible)


Steps to Implement or Execute Code

  1. Download the attached Zip file
  2. Open  File Path Example 2012 NIVerified "
  3. Run  Test VI " and view the file paths generated
  4. Open " Application.exe " from the Executable directory
  5. Observe the difference in paths generated

 

Additional Information or References
VI Block Diagram of "Test VI"

 Block Diagram.png

 

 **This document has been updated to meet the current required format for the NI Code Exchange.**

 


Regards,

Peter D

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.