Previous: 4.67.2.70. Reset procedure To the Table of Contents Next: 4.67.2.72. RmDir procedure
4.67.2.70. Reset procedure Table of Contents 4.67.2.72. RmDir procedure

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


4.67.2.71. ReWrite procedure

Targets: MS-DOS, OS/2, Win32


System Unit

Creates and opens a new file.

Declaration:
procedure ReWrite(var F: File[; RecSize: Longint ] );
Remarks:
F is a file variable of any type which was previously associated with a file name by a call to Assign.

RecSize indicates the size in bytes of each record and can only be passed if F is an untyped file.

Note that RecSize is not limited to 65,535 (64K) bytes.

If F exists or is open when ReWrite is called, F is closed, deleted, and then recreated. If F is assigned to an empty string (), standard input is used. Text files are created as write-only. With {$I-}, IOResult returns an error code if an error occurred, otherwise it is set to zero.

See also:
{$I} - I/O Checking Switch


Previous: 4.67.2.70. Reset procedure To the Table of Contents Next: 4.67.2.72. RmDir procedure
4.67.2.70. Reset procedure Table of Contents 4.67.2.72. RmDir procedure

- 4.67.2.71. -