LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Getting Packed Project Library Build Number

Solved!
Go to solution

Is there a way to get a packed project library's version number like there is for an executable?

0 Kudos
Message 1 of 9
(2,621 Views)

LibraryVersion.png

 

 

George Zou
0 Kudos
Message 2 of 9
(2,610 Views)

A Packed Project Libaries file version is the same as the version in the build configuration. You can look at the file version just like you would for an executable.

0 Kudos
Message 3 of 9
(2,596 Views)

How I normally get the version number is returning the executable version number not the PPL.

 

I tried getting the version number like this site suggests, and it didn't work. The string returned was blank. I called the suggested code from a VI inside the PPL.

 

I tried using the Project.Libraries[] property node but it neve returned any references. It was strange because I enabled scripting, but I still can't see that item under the property node of App. I copied and pasted the snippet you provided and the VI compiled, but as you see below it still does not appear as an option.

 

Project Libraries.png

 

I am using these packed project libraries as plugins. I am trying to get the version number of the ppl from a VI inside the PPL. I can work with getting the version number from a VI outside the PPL, so far I just can't seem to get a version number that is not the executable.

0 Kudos
Message 4 of 9
(2,544 Views)

While it puts more responsibility on you, the Developer, you could write a "Constant VI" (one that has only an output Indicator whose default Value is set by you) called something like "PPL Version" to return this number.  This would place these data fully under your control without you needing "hooks" into aspects of LabVIEW that NI has not provided (yet), possibly because they are not "safe from modification" or because messing with them can have unforseen consequences.

 

Bob Schor

0 Kudos
Message 5 of 9
(2,528 Views)

It seems you can only get the version number of the .lvlib (the source), not .lvlibp.

So if you set the packed lib version # to the same as the source, then it will work.

 

 

George Zou
0 Kudos
Message 6 of 9
(2,522 Views)
Solution
Accepted by LJHerskowitz

I have been able to retrieve the PPL version programtically at run-time with no issue. It requires adding an extra VI to the project library so that it can interrogate itself:

 

 

PPL Version.png

Message 7 of 9
(2,507 Views)

This same basic logic also works from outside the PPL as well. All you have to do is pass into it a reference to a VI that is in the PPL, and everything else just works.

Mike...


Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 8 of 9
(1,198 Views)

@Mike,

Your blog link doesn't work.

 

George Zou
0 Kudos
Message 9 of 9
(1,193 Views)