Previous: 4.67.2.2. Addr function To the Table of Contents Next: 4.67.2.4. ArcTan function
4.67.2.2. Addr function Table of Contents 4.67.2.4. ArcTan function

- 4.67.2.3. -
Table of Contents
4. Standard Units
4.67. System - Built-in routines
4.67.2. System Unit Procedures and Functions
4.67.2.3. Append procedure


4.67.2.3. Append procedure

Targets: MS-DOS, Win32

System Unit

Opens an existing file for appending.

Declaration:
procedure Append(var F: Text);
Append works only if the file exists. It sets the file pointer to the end of the file. If F is open when Append is called then F is first closed and then reopened. If one assigns an empty file name to F, output will be directed to the standard output file. Errors are returned through IOResult if {$I-}.

If there are no errors then IOResult returns zero.

Example:
{$ifndef __CON__}
  This program must be compiled as console application only
{$endif}
var
  Fi:Text;
begin
  Assign(Fi, 'THE_FILE.TXT');
  Append(Fi);
  WriteLn(Fi, 'Just testing Append.');
  Close(Fi);
end.
See also:
{$I} - I/O Checking Switch


Previous: 4.67.2.2. Addr function To the Table of Contents Next: 4.67.2.4. ArcTan function
4.67.2.2. Addr function Table of Contents 4.67.2.4. ArcTan function

- 4.67.2.3. -