Class to perform Ini reading and writing operations
Created as a complete replacement of the default Ini commands
- Much much faster than the default Ini operations.
- Support for reading/writing linked comments to keys and sections.
- Same syntax as the default Ini commands.
Example of an Ini created through the lib
Sets a pointer to an Ini settings file.
The Ini file is created if it doesn't exists.
- .Read(Section="", Key="", Byref Key_com="", ByRef Sec_com="")
Reads value of the Key contained in a Section to the outputvar.
If the Byref parameters are specified, the linked Key comments (Key_com) and Section comments (Sec_com) are also read.
If Section="" i.e. the first param is unspecified, the list of sections in the ini will be returned in a fashion similar to the AHK_l IniRead command.
If Key="" , the list of Keys in the specified Section is returned.
- .Write(Section, Key, Value, Key_com="", Sec_com="")
Write values to a key, creating the key and section if necessary.
Sec_comare for key and section comments.
If these params are omitted, then the original corresponding comment is left unchanged but if
these params are called as a Space
(" " or A_space), then the linked comment for the section/key is deleted and changed to null.
- .Delete(Section="", Key="")
Delete keys or sections from the ini.
If Key is omitted , the whole section is deleted.
If Section is omitted , the whole Ini is deleted.
Saves the changes made to the Ini made in memory to the file.
Remember to call
.Saveafter making the changes.