IniDelete

Deletes a value from a standard format .ini file.

IniDelete, Filename, Section , Key

Parameters

Filename

The name of the .ini file, which is assumed to be in %A_WorkingDir% if an absolute path isn't specified.

Section

The section name in the .ini file, which is the heading phrase that appears in square brackets (do not include the brackets in this parameter).

Key

The key name in the .ini file. If omitted, the entire Section will be deleted.

Error Handling

[v1.1.04+]: This command is able to throw an exception on failure. For more information, see Runtime Errors.

ErrorLevel is set to 1 if there was a problem or 0 otherwise.

Remarks

A standard ini file looks like:

[SectionName]
Key=Value

IniRead, IniWrite, RegDelete

Examples

Deletes a key and its value located in section2 from a standard format .ini file.

IniDelete, C:\Temp\myfile.ini, section2, key