The memoWrit() function writes the content of a JavaScript string to a file.
Note: If the file exists, it can either replace the existing file or append the string to the existing string content.
The function has the following syntax:
memoWrit(sFileName, sString [, bAppend])
Defines the string.
Defines the name of a text file. If the specified file does not exist, the function raises an exception.
If set to true, the function adds the string to the given file.
The function returns with the number of bytes written to the specified file.
Note: If there are problems accessing the file, the function creates an exception.
Examples
Write a single-line text file:
memoWrit("file.txt", "First line\");
Append a second line to the existing file:
memoWrit("file.txt","Second line\", true);
Copyright © 2013 CA. All rights reserved. |
|