Company Events Academic Community Support Solutions Products & Services Contact NI MyNI

Building a Stand-Alone Application

LabVIEW 8.2 Help
August 2006

NI Part Number:
371361B-01

»View Product Info
Download Help (Windows Only)

You can use the Application Builder tools to create a build specification for and build a stand-alone application (EXE). Before you create a build specification or start the build process, review the caveats and recommendations for LabVIEW build specifications.

Note  The LabVIEW Professional Development System includes the Application Builder. If you use the LabVIEW Base Package or Full Development System, you can purchase the Application Builder separately by visiting the National Instruments Web site.

Complete the following steps to build an application in LabVIEW.

  1. Open the LabVIEW project you want to use to build the application. You must have a project open and saved to configure a build specification.
  2. Prepare the VIs you want to use to build the application. Save changes to any VIs in memory.
Note  If you do not have a project for the application, you can use the Build Executable Wizard dialog box to create a project. From an open VI, select Tools»Build Executable to launch the Build Executable Wizard, which guides you through the process.
  1. Expand My Computer. Right-click Build Specifications and select New»Application from the shortcut menu to display the Application Properties dialog box.
  2. Complete the following items on the Application Information page of the Application Properties dialog box.
    1. Enter a name for the build specification in the Build specification name text box. This name appears under Build Specifications in the Project Explorer window. The name must be unique among other build specification names in the project.
    2. Enter a name for the application in the Target filename text box. Windows Applications must have a .exe extension. Mac OS Applications must have a .app extension. Linux Applications should not have an extension.
    3. Enter the location for the built application in the Application destination directory text box. You can use the Browse button to navigate to and select a location.
    4. Enter the version information for the application in the Version Information section.
  3. Complete the following items on the Source Files page.
    1. From the Project Files tree, select the VI you want to define as a startup VI, also known as a top-level VI, for the application. Startup VIs open and run when a user launches the application. You must define at least one VI as a startup VI for each application you build.
    2. Click the right arrow button next to the Startup VIs listbox to move the selected VIs to the Startup VIs listbox.
    3. From the Project Files tree, select the items you want to define as dynamically called VIs or non-VI support files, such as data files.
    4. Click the right arrow button next to the Dynamic VIs and Support Files listbox to move the selected items to the Dynamic VIs and Support Files listbox.
Note  You cannot include a polymorphic VI in the Startup VIs or Dynamic VIs and Support Files listboxes. Use an instance of the polymorphic VI instead.
Note  The LabVIEW Run-Time Engine must be installed on any computer on which users run the application or shared library. You can distribute the LabVIEW Run-Time Engine with the application or shared library. Windows You also can include the LabVIEW Run-Time Engine in an installer.
Note  If you build an application that uses VIs on the Source Control palette, there is no automatic way to add the source control configuration information to the.ini file for the built application. You must manually add the SCCConfigData, SCCProviderName, and SCCProviderLocation tokens to the .ini file for the application or to a custom .ini file if you are building an installer.
  1. From the Destinations page, configure destination settings and add destination directories for the application.
  2. From the Source File Settings page, edit destinations and properties for individual files and folders in the application. If a VI specified as a Dynamic VI is going to a destination other than the built application or DLL, Application Builder will move all dependencies of the dynamic VI to the new destination with the dynamic VI, rather than keep the dependencies in the built executable. If two or more dynamic or top level VIs call a VI and try to move it to two different locations, Application Builder will move the VI and all subVIs to the built executable. To make a VI that is specified as Include only if referenced move to a new location, you must specify the VI as a Dynamic VI
Note  If you plan to distribute a stand-alone application that uses shared variables, do not include the .lvlib file in an LLB or in the executable. Change the Destination of the .lvlib file to a destination outside the executable or LLB.
  1. From the Icon page, select the icon file to associate with the application.
  2. From the Advanced page, configure advanced settings for the application.
  3. From the Run-Time Languages page, set the language preferences for the application.
  4. From the Preview page, click the Generate Preview button to review the generated files for the application.
Note  Save changes to VIs in memory before you create or edit a build specification to ensure that the preview is accurate.
  1. Click the OK button to update the build specification settings in the project and close the dialog box. The build specification name appears in the project under Build Specifications.
Note  Creating or updating the build specification does not build the application.
Note  When you update the build specification settings, the settings become part of the project. However, you must save the project if you want to save the settings.
  1. Right-click the application build specification name and select Build from the shortcut menu. You can find the resulting application in the directory specified in the Destination path on the Destinations page.
Note  You also can click the Build button in the Application Properties dialog box to update the build specification and build the application.

You can duplicate build specifications. Right-click the build specification item you want to duplicate and select Duplicate from the shortcut menu to create a copy of the build specification item.

You also can build an application programmatically from a build specification.


Resources

WAS THIS ARTICLE HELPFUL?

Not Helpful