saveTextFile: Difference between revisions

From GTA Connected
Jump to navigation Jump to search
No edit summary
No edit summary
Line 7: Line 7:
|parameter2 = string text The text to set the content of the file to.
|parameter2 = string text The text to set the content of the file to.
|returnTypes = null n/a
|returnTypes = null n/a
|usage = set all text inside a file to.<br>The text may contain new-line character(s).<br>The text stored is either up to text's string length or first null-byte (\0) character, whichever occurs first.<br>This function internally opens, writes, and closes the file.<br>The file is internally opened in text-mode, not binary-mode.<br>The file is internally opened in write-mode, not read-mode.
|usage = write a string of text to a file, truncating the file first
|returnFail1 = null n/a
|returnFail1 = null n/a
}}
}}

Revision as of 01:20, 3 December 2020

Function Server and Client icon-iii.png icon-vc.png icon-sa.png icon-iv.png Online and Offline

Available since Server 1.0.0, Client 1.0.0

null saveTextFile(string filePath, string text)

The saveTextFile function is used to write a string of text to a file, truncating the file first.

Parameters

1) string filePath The path to the file.
2) string text The text to set the content of the file to.

Return

null This function doesn't return a value.

Notes

There aren't any notes for this function.

Examples

There aren't any examples for this function.

Compatibility

There isn't any compatibility information for this function.

Related

Server Related

icon-iii.png icon-vc.png icon-sa.png icon-iv.png createFile
icon-iii.png icon-vc.png icon-sa.png icon-iv.png fileExists
icon-iii.png icon-vc.png icon-sa.png icon-iv.png loadTextFile
icon-iii.png icon-vc.png icon-sa.png icon-iv.png openFile
icon-iii.png icon-vc.png icon-sa.png icon-iv.png saveTextFile


Client Related

icon-iii.png icon-vc.png icon-sa.png icon-iv.png createFile
icon-iii.png icon-vc.png icon-sa.png icon-iv.png fileExists
icon-iii.png icon-vc.png icon-sa.png icon-iv.png loadTextFile
icon-iii.png icon-vc.png icon-sa.png icon-iv.png openFile
icon-iii.png icon-vc.png icon-sa.png icon-iv.png saveTextFile