LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to hold data even closing the VI?

Solved!
Go to solution

Hello guys.

I'm using a VI to measure the force applied to a load cell (strain gage). I wish I could calibrate it between defined periods, so I wish I could insert a data (the number I have to multiply the load cell voltage, wich one is in volts) in any moment, but I want that this number stay into the VI when I close it and than open it again. If possible, I would like to protect this data with a key.
Is it possible
Sorry for my bad english!

Hope you can help me!

Thank you!!

0 Kudos
Message 1 of 15
(3,216 Views)

sorry, I meant:

Is it possible?

0 Kudos
Message 2 of 15
(3,200 Views)

The simple way would be write the value to a file and then read it when you start the code.

-----

The best solution is the one you find it by yourself
0 Kudos
Message 3 of 15
(3,193 Views)

Best way to use all the VIs in one common file and pass the wanting value from 1 VI to other using global variable.

--------------------------------------------------------------------------------------------------------
Kudos are always welcome if you got solution to some extent.

I need my difficulties because they are necessary to enjoy my success.
--Ranjeet
0 Kudos
Message 4 of 15
(3,181 Views)
Solution
Accepted by ManuSpadim

As Anand says, the easy way is to just write the data to a file, but then it wont be protected. You can write it as a registry key in which case it's somewhat protected by being somewhat hidden and you can easily make a password-vi to allow modification of this value.

 

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 5 of 15
(3,174 Views)

Writing to registry is a good way to save the top level configuration parameters like Checksum values. But for the data still I would go for writing to file like binary files (Cannot be edited manually) so your file is protected to a level. If you want to increase the number of parameters you can still easily do it.

-----

The best solution is the one you find it by yourself
0 Kudos
Message 6 of 15
(3,169 Views)

There is absolutely no problem in using file but if labview has given you facility then why not use it, just saying  Smiley Wink  ?

 

--------------------------------------------------------------------------------------------------------
Kudos are always welcome if you got solution to some extent.

I need my difficulties because they are necessary to enjoy my success.
--Ranjeet
0 Kudos
Message 7 of 15
(3,168 Views)

@Ranjeet_Singh wrote:

There is absolutely no problem in using file but if labview has given you facility then why not use it, just saying  Smiley Wink  ?

 


I don't understand which facility you meant here. 🙂

-----

The best solution is the one you find it by yourself
0 Kudos
Message 8 of 15
(3,160 Views)

Read about global variable

--------------------------------------------------------------------------------------------------------
Kudos are always welcome if you got solution to some extent.

I need my difficulties because they are necessary to enjoy my success.
--Ranjeet
0 Kudos
Message 9 of 15
(3,156 Views)

Using a file and the registry key is different and global variable is different. Global varaible comes into play after reading from the file or reg key but the question here is to preserve the value somehwere even after closing the vi.

-----

The best solution is the one you find it by yourself
0 Kudos
Message 10 of 15
(3,150 Views)