janozzy
asked on
Ini_file
Hi all
I need to write a small progman.
program read and write to ini-file.
And i want to keep inifile in program homedirectory
this code works but Is there any other way to locate file?
pelaajatiedot:=Tinifile.Cr eate('c:\h omedir\Pac kAliases.i ni');
Thanks
Janozzy
I need to write a small progman.
program read and write to ini-file.
And i want to keep inifile in program homedirectory
this code works but Is there any other way to locate file?
pelaajatiedot:=Tinifile.Cr
Thanks
Janozzy
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
glad to helped you ;-)
I find it very handy to use ChangeFileExt() like so:
var
IFile: TIniFile;
begin
try
IFile := TIniFile.Create(ChangeFile Ext(params tr(0),'.in i'));
//do stuff
finally
FreeAndNil(IFile);
end;
end;
reddarin =)
var
IFile: TIniFile;
begin
try
IFile := TIniFile.Create(ChangeFile
//do stuff
finally
FreeAndNil(IFile);
end;
end;
reddarin =)
ASKER
Thanks