Syntax
IncludeIniFile( FileName:String )
Parameters
FileName:String
Full path to file with params
Return value
If file exists function return 1, otherwise function return 0.
Remarks
With function IncludeIniFile you can read some parameters from file. Parameters must be represent in format <key>=<value>. E.g. after including file, with content
a=1
s=some text
you become in scrtipt 2 variables : a:integer with value 2 and s:string with value ‘some text’.
Example
For these example you must create text file with content
i=1
s=Hello world!
(or download it from here)
and save it as ‘c:\sometext.txt’.
IncludeIniFile('c:\sometext.txt');
MSGBox('i = ' + ToString(i));
MSGBox('s = ' + s);
Download example IncludeIniFile.
Leave a Reply