WriteChar(Value: Char);
Value. The character that must be written.
The WriteChar method writes characters into a text file.
Sub UserProc;
Var
f: IFileStream;
TxtWriter: ITextWriter;
Begin
f := New FileStream.Create("c:\File.txt", FileOpenMode.Create, FileShare.Exclusive);
TxtWriter := New TextWriter.Create(f);
TxtWriter.WriteChar(#169);
TxtWriter.WriteString("New Line");
TxtWriter.Flush;
Dispose f;
End Sub UserProc;
On executing the example a new text file File.txt is created. The character with the 169 (©) code and the selected character string are written to the file.
See also: