Language:
Русский
English
Write (procedure)
For typed files, writes a variable into a file component. For text files, writes one or more values to the file
Declaration
Typed files
procedure Write(F, V1 [, V2,...,Vn ] );
Text files
procedure Write( [ var F: Text; ] P1 [,P2,...,Pn ] );
Target
Windows, Real, Protected
Remarks
File must be open for input.
F if specified is a text file variable.
Text files
Each P is a write parameter which includes an output expression whose
value is to be written to the file.
A write parameter can also contain the specifications of field width, and
number of decimal places.
Each output expression must be of type Char, Integer, Real, string,
packed string, or Boolean.
Typed files
Each V is a variable of the same type as the component type of F.
For each variable written, the current file position is advanced to
the next component.
If the current file position is at the end of the file, the file is
expanded.
Return Values
{$I-} IOResult returns 0 if the operation was sucessful, otherwise a nonzero error code.