uses inifiles, ......procedure savetoini(const aFileName:string);var vIni : TIniFile;begin vInit := Tinifile.Create(aFilename); try vini.writestring('Main','CurrentPath',MySelectedPathVar); finally vini.free; end;end;
Tinifile has a format of varname=varvalue a plain text file does not give you that information with out extra coding and if you are going to code the above behavior any way why not use the ini files from the start
http://wiki.freepascal.org/Using_INI_Files
A little more info please.Do I use this line when I want to read in from the file too ?TInifile.Create(aFilename)There's no TInifile.Open I presume.Thanks
Are there more values written into the ini file?