Reference/FileWrite: Difference between revisions

From NSIS Wiki
Jump to navigationJump to search
(Created page with "=FileWrite= handle string Writes an ANSI string to a file opened with FileOpen. If an error occurs writing, the error flag will be set. (If you are bui...")
(No difference)

Revision as of 20:15, 27 November 2011

FileWrite

handle string

Writes an ANSI string to a file opened with FileOpen. If an error occurs writing, the error flag will be set.

(If you are building a Unicode installer, the function makes the adequate conversion and writes an ANSI string)

ClearErrors
FileOpen $0 $INSTDIR\file.dat w
IfErrors done
FileWrite $0 "some text"
FileClose $0
done: