LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to write a single key/value to a configuration file?

Hello-
 
I use the configuration VIs extensively.  Currently I use the Config Data Write To File.vi within the config.llb to update the config file on *disk* when I don't want to close the reference to the configuration data internally in RAM.  However, Config Data Write To File.vi writes the ENTIRE configuration image to the .ini file.  Is there a known way to simply write a SINGLE key to the .ini file on *disk* (Write Key.vi changes only the RAM copy of the parameter...Close Config Data.vi calls Config Data Write To File.vi, which of course writes the entire configuration image)?  I'm at the point where I'm thinking about re-writing some of the functions in config.llb to serve this purpose, but I thought I'd check to see if anybody has done something like this before.
 
Thanks,
-Robert
0 Kudos
Message 1 of 2
(2,912 Views)
Hi Robert
 
Intuitively, when you change anything in a file the whole file needs to be saved to keep your changes so I would say you can't avoid having to save the whole file.
 
If you want to avoid the save in Close Config Data then set "write configuration file? = false"
 
 
I am referring to Config VIs in LV8.
 
Get back to me if I have misunderstood your problem.
 
David

Message Edited by David Crawford on 01-20-2006 04:33 AM

Message Edited by David Crawford on 01-20-2006 04:35 AM

Sorry, the picture was completely wrong now corrected.

Message Edited by David Crawford on 01-20-2006 04:36 AM

0 Kudos
Message 2 of 2
(2,905 Views)