home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Media Share 9
/
MEDIASHARE_09.ISO
/
pascal
/
tplib21.zip
/
INSTALL.EXE
/
EXSTDERR.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1993-05-30
|
1KB
|
29 lines
(* Example program: STDERR unit *)
PROGRAM EXSTDERR;
USES
STDERR;
BEGIN
WriteLn('EXSTDERR - STDERR UNIT EXAMPLE PROGRAM');
WriteLn;
WriteLn('This text is being sent to the standard output device.');
WriteLn('DOS allows redirection of standard output to any file');
WriteLn('or device by the ">" and "|" symbols on the command line.');
WriteLn;
WriteStdErr('This text, on the other hand, is being sent to the');
WriteStdErr('standard-error device, which is always the console.');
WriteStdErr('Text sent to the error device is not affected by any');
WriteStdErr('redirection.');
WriteLn;
WriteLn('We are now back to the standard output device. Notice how');
WriteLn('all this text has appeared on the console display. Try ');
WriteLn('running this program again, redirecting output to a file or');
WriteLn('your printer. You should only see the middle paragraph of text');
WriteLn('appear on your console screen; the other text (including this)');
WriteLn('will be sent to the printer or disk file.');
END.