Example Code

Programmatically Load/Save 'Default' Control Values Using LabVIEW

Products and Environment

This section reflects the products and operating system used to create the example.

To download NI software, including the products shown below, visit ni.com/downloads.

    Software

  • LabVIEW

Code and Documents

Attachment

Download All

Overview

The example to save and load front panel control values to/from a .ini file.

 

Description

There are a number of ways to save a set of control values to load at a later date. Here are two VIs which allow you to save and load front panel control values to/from a .ini file. The example automatically populates an xml file with all current control values to the VI's front panel.

 

Requirements

  • LabVIEW 2012( or compatible)

 

Steps to Implement or Execute Code

  1. Run the vi.
  2.  Hit 'save' - this will save a .INI file with all control information to the specified path
  3.  Hit 'load' you will notice that they return to the originally saved values

 

Additional Information or References

Front Panel

FP.JPG

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

 

Eden S
Applications Engineer
National Instruments UK & Ireland

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

Comments
steve_robbins
Member
Member
on

Many thanks,  this works very well!  Even on array of clusters containing arrays of clusters!!!!

Tom98765
Member
Member
on

Really nice, even with hideously complex controls, but not if there are controls with multi-line labels. Very many thanks.