[Lazarus] Unable to rewrite .ini file which exists... error unable to create .ini file. (need to rewrite it).

Bart bartjunk64 at gmail.com
Tue Mar 15 12:45:49 CET 2011


On 3/15/11, Peter Williams <pewilliams2010 at live.com> wrote:

> ConfigIni := TIniFile.Create(ChangeFileExt(Application.ExeName,'.ini'));

You really should not do that in most OS's, even on Windows it is
deprecated since win9x.
Most times you will not have write permissions there.
Also under *nix this location might not be what you expect it to be...

Use GetAppConfigDir to determine where to put INI files.

Bart




More information about the Lazarus mailing list