LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

storing values in memory and retrieving

Hi,

I am having trouble saving things to memory.  What I am trying to accomplish is to save the current values to memory so that if the program closes and is opened again, everything stays the same.

Right now the program works sometimes and sometimes it doesn't and I'm not sure what the problem is.  The window I'm showing you is actually part of a larger data acquisition program.  This is the initialization windows and runs first thing.  Later in the program, all the values are stored into the global variables.  Sometimes, the program restarts with all the global variables = 0 and sometimes it saves the values from the previous run.

Thanks in advance for the help

Yin


0 Kudos
Message 1 of 2
(3,120 Views)
If you stop a VI and it remains in memory, it will retain whatever values it had from the last run when you restart it.  If the VI's do not remain in memory, but open up fresh from disk, then the VI's will contain the values that were stored on the controls whenever the Data Operations/Make current value default was clicked for the control or Edit/Make current values default  for all controls.  If you only need to save a set of values permanently, then the Edit/Make Current Values default will work.  If the default values need to change from run to run, then use the Config file VI's to save the current values before the program ends, and reload them when the program starts.
0 Kudos
Message 2 of 2
(3,111 Views)