Command:/ini

From the wonderful RedGuides Wiki

This command is added by MacroQuest

Syntax Key
Notation Description
Text without brackets or braces Required items
<Text inside angle brackets> Placeholder for which you must supply a value
[Text inside square brackets] Optional items
Vertical bar (|) Separator for mutually exclusive items; choose one
{Text | inside | braces} Set of required items; choose one
Ellipsis () Items that can be repeated
Syntax /ini "filename" "keyname" "valuename" "value"
Description Outputs string data to an INI file.

Options

Examples

Example use of /ini command Description
/ini "someini.ini" "the section" "NULL" "NULL" adds a key named NULL and a value named NULL under the [the section]:
/ini "someini.ini" "the section" "NULL" NULL to remove the key named NULL:
/ini "someini.ini" "the section" NULL to remove section "the section":

Example of use;

MyStuff.ini contains the following data:

[MySection]
; This is a comment
Key1=123
Key2=Combat action code
Key3=Spell_name

The following command is run:

/ini "MyStuff.ini" "Section2" "ANewKey" "Some Data!"

MyStuff.ini will now contain the following:

[MySection]
; This is a comment
Key1=123
Key2=Combat action code
Key3=Spell_name

[Section2]
ANewKey=Some Data!

See also