###Function###
IniWriteSection

###Description###
Writes a section to a standard format .ini file.

###Syntax###
IniWriteSection ( "filename", "section", "data" [, index = 1] )


###Parameters###
@@ParamTable@@
filename
	The filename of the .ini file.
section
	The section name in the .ini file.
data
	The data to write.  The data can either be a string or an array.  If the data is a string, then each key=value pair must be delimited by @LF.  If the data is an array, the array must be 2-dimensional and the second dimension must be 2 elements.
index
	[optional] If an array is passed as data, this specifies the index to start writing from.  By default, this is 1 so that the return value of <a href="IniReadSection.htm">IniReadSection()</a> can be used immediately.  For manually created arrays, this value may need to be different depending on how the array was created.  This parameter is ignored if a string is passed as data.
@@End@@

###ReturnValue###
@@ReturnTable@@
Success:	1.
Failure:	0. The function will sets the @error flag to 1 if the data format is invalid.
@@End@@


###Remarks###
A standard ini file looks like:
<i>[SectionName]
Key=Value</i>
If file does not exist, it is created. Any directories that do not exist, will not be created. Keys and/or sections are added to the end and are not sorted in any way.
If the section being written already exists, its contents will be overwritten.

If you want to use an ini file with unicode encoding, first create an .ini file by using the <a href="FileOpen.htm">FileOpen()</a> function with the mode parameter set to "Unicode UTF16 Little Endian".


###Related###
IniDelete, IniRead, IniReadSection, IniReadSectionNames, IniWrite, IniRenameSection


###Example###
@@IncludeExample@@
