Skip to main content
Skip table of contents

f$TextFileWrite (f$TextDateiSchreiben)


f$TextFileWrite (f$TextDateiSchreiben)

Writes a text into a file. If file exist, the existing content will be overwritten. If file does not exist, it will be created.

Please note that, when entering a path in the file name, the backslash ( \ ) character must be entered twice (e.g. "C:\\Directory\\TextFile.txt").

Syntax:

Status = f$TextFileWrite( FileName, ParaNameContent, Encoding)

 

Argument

Type

Meaning

 

FileName

String

Name of the file to be written. Please provide the complete path. (Target)

 

ParaNameContent

String

Name of the parameter containing the text to be written into the file. (Source)

 

Encoding

Integer

0: ANSI (Default)
1: UTF-8
2: UTF-16LE (Little Endian)

Result:

Integer

0: The file has successfully been written.
-1: The file couldn't be opened / created.
-2: The process of writing into the file has been canceled.
-3: The process of writing into the file has been canceled because of an illegal byte sequence (EILSEQ).

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.