Example Code

Get LabVIEW Project Library (.lvlib) Version Programmatically 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

This example demonstrates how to programmatically obtain the version numbers of all project library files present in a LabVIEW project

  

Description

The version information of any project library can be changed by accessing the properties menu of the project library by right clicking the library file in the LabVIEW project. As shown in the image below you can add different types of version numbers like 'Major', 'minor' , 'fix' and 'build' in order to keep track of the changes you make to the library file

 

Requirements

Software

LabVIEW 2013 (or compatible)

A LabVIEW project containing the project libraries (.lvlib)

Hardware

None

  

Steps to Implement or Execute Code

  1. Add the 'library version.vi' file to the LabVIEW project containig the project library files whose version information you want to access programmatically (make sure the the .lvlib files are present immediately under the 'my computer' target)
  2. Open the front panel of the 'library version.vi' and enter the name of the project which contains the LabVIEW libraries along with the .lvproj extension (refer to the image below which shows the front panel)

3. Run the VI to obtain the version information of all the project libraries in your LabVIEW project.

4. A VI snippet of the commented block diagram explaing the different sections of the code is added as an image below. The actual VI can be downloaded from the attachments section

 

 

Additional Information or Reference

 

library_version.PNGThere may be situation when you want to programmatically access this version information of project libraries in your LabVIEW code. This example code demonstrates how to achieve this.

 

1-373 FD.png 

 

block_diagram.png

 

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

 

Thanks and Regards,
Supreeth.K

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