LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Make Current Value Default

Hi,

I am developing a new program in which I am interesting in modify the default value of a variable when I exit the program, so when I boot again the program the default value is the last value which has been modified by the process. My question is if it is possible to do this by means of any operation with Labview (property node, reference, etc..)? We thought another possibility, saving the value in a file and recovering each time the program is launched.

 

Thanks in advance,

 

Juancar

 

0 Kudos
Message 1 of 5
(7,827 Views)

Saving and loading a file is the way to go.

 

You can't programatically set the values of running VIs to default.

 

Shane.

Message 2 of 5
(7,824 Views)

There is a Method available in the VI Server class, called Default Values >> make Current Default. But it WILL work only in the Edit mode of the VI, NOT in the Run mode.

 

So, file [INI file] maintenance is the best choice, like Shane has mentioned earlier.

- Partha ( CLD until Oct 2027 🙂 )
Message 3 of 5
(7,817 Views)

Thank you very much

Regards

0 Kudos
Message 4 of 5
(7,808 Views)

Hi Juancar,

 

You can use a default constant value cabled to a local variable at the end of your data flux to make sure your control/indicator reinitializes to default value (see image attached).

 

Regards,

David Oña
Message 5 of 5
(7,761 Views)