LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Generate version nr.

Hi,
 
I made a Subvi that generates a string that is used as version ID for the top level VI. Its derived from the VI revision nr. See example. This works fine. But when I compile the VI to an EXE my Subvi that generates the version ID returns an error. Someone knows how to get this working even in the EXE. (Check the Archive attached)
 
Thnx,
 
B. Bakels
Labview CLD , Engineer/Manager

Promedes and DSM
using LV 7.1, 8.0, 8.2, 8.5 and 2009 SP1
http://www.promedes.nl
0 Kudos
Message 1 of 10
(3,714 Views)
example is 8.0 btw
Labview CLD , Engineer/Manager

Promedes and DSM
using LV 7.1, 8.0, 8.2, 8.5 and 2009 SP1
http://www.promedes.nl
0 Kudos
Message 2 of 10
(3,697 Views)
Hello BartB,

I made the same for my projects...
You cannot ask for the revision history in executables! This property is only available in development environment, as described in the help.
But: you can make a control in your subVi and copy the revision history to a local of this control. When you change the reivision history, run the vi once and set the control to "make current value default". When you run your executable, check for executable or development environment and use either the revision history property node or the control (with it's default value...). So you get the actual rev history even in executable mode!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 3 of 10
(3,689 Views)
Hi GerdW
 
Thanx that is a great idea, thnx. points are comming your way 😉
 
BartB
Labview CLD , Engineer/Manager

Promedes and DSM
using LV 7.1, 8.0, 8.2, 8.5 and 2009 SP1
http://www.promedes.nl
0 Kudos
Message 4 of 10
(3,678 Views)
I encoutered another problem, Labview 8.0 cant make values default programmaticly when  the VI is running. I m thinking of using an config file solution (ini) wich stores the last  revision nr. Any other ideas or examples?
 
Thnx

Message Edited by bartb on 04-10-2006 03:36 PM

Labview CLD , Engineer/Manager

Promedes and DSM
using LV 7.1, 8.0, 8.2, 8.5 and 2009 SP1
http://www.promedes.nl
0 Kudos
Message 5 of 10
(3,670 Views)
Hello BartB,

I don't set the default values programmatically... It's the last step of "editing" before building a new executable.
Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 6 of 10
(3,664 Views)
Hi,


This is indeed very inconvenient. What you can do is this.


During testing (e.g. development environment) copy the string to the vi description. You can use prefixes, xml tags, etc. so you can still use the normal vi description.


During the development, you will save the vi's with the new revision info in the description. If you don't save the old revision info will stay in the description, just how it should be.

From the executable, you can still query the description.


It's a hack, but it works.


Regards,


Wiebe.


"bartb" <x@no.email> wrote in message news:1144429807054-349515@exchange.ni.com...
Hi,
&nbsp;
I made a Subvi that generates a string that is&nbsp;used as version ID for the top level VI. Its derived from the VI revision nr. See example. This works fine. But when I compile the VI to an EXE my Subvi that generates the version ID returns an error. Someone knows how to get this working even in the EXE. (Check the Archive attached)
&nbsp;
Thnx,
&nbsp;
B. Bakels



Create Version Nr.zip:
http://forums.ni.com/attachments/ni/170/178383/1/Create Version Nr.zip
0 Kudos
Message 7 of 10
(3,662 Views)
thnx Wiebe
Labview CLD , Engineer/Manager

Promedes and DSM
using LV 7.1, 8.0, 8.2, 8.5 and 2009 SP1
http://www.promedes.nl
0 Kudos
Message 8 of 10
(3,657 Views)
still having problems lol. It seems it isnt possible to readout the description tag in a runtime build in labview 8..?
Labview CLD , Engineer/Manager

Promedes and DSM
using LV 7.1, 8.0, 8.2, 8.5 and 2009 SP1
http://www.promedes.nl
0 Kudos
Message 9 of 10
(3,638 Views)
Haven't tried it in 8... So I can't confirm. Sorry about that.


I'll try it out, unless someone does it before me. It might take me a while (have to install 8 first etc.).


Regards,


Wiebe.




"bartb" <x@no.email> wrote in message news:1144777209067-350839@exchange.ni.com...
still having problems lol. It seems it isnt possible to readout the description tag in a runtime build in labview 8..?
0 Kudos
Message 10 of 10
(3,624 Views)