[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
NAME: AssignCrt
USE: Associates a text file variable to the CRT.
DEPENDENCY: The CRT unit must be used placed in the uses section.
SYNTAX: AssignCrt(FileVariable);
EXAMPLE: Program TestAssignCrt;
Var
FVar : Test;
Answer : Char;
Begin
Write('Output Test to (S)creen (P)rinter or (D)isk? ');
Answer := UpCase(ReadKey);
Case (Answer) of
'S' : AssignCrt(FVar);
'P' : Assign(FVar,'PRN');
'D' : Assign(FVar,'TEST.TXT');
end;
ReWrite(FVar);
Writeln(FVar,'This is a test of AssignCrt');
Close(FVar);
end.
See Also:
Append
Assign
Close
Reset
ReWrite
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson