home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / PASCAL / EXIST4.ZIP / ETEST.PAS next >
Encoding:
Pascal/Delphi Source File  |  1988-04-20  |  636 b   |  34 lines

  1. Program ExistTest;
  2. Uses
  3.    Dos,
  4.    Crt;
  5.  
  6. Type
  7.    String80 = String[80];
  8.  
  9. Var
  10.    FileName : String80;
  11.    DiskFile : File;
  12.  
  13. {$i exist4.inc}
  14.  
  15. Begin
  16.    Clrscr;
  17.    Repeat
  18.       Write('Disk file name: ');
  19.       Readln(FileName);
  20.       Write('File ',Filename);
  21.       if Exist(FileName) then
  22.       Writeln(' exists.') else
  23.       Writeln(' does not exist.');
  24.       writeln;
  25.       Write('Directory name: ');
  26.       Readln(FileName);
  27.       Write('Directory ',FileName);
  28.       if DirExist(FileName) then
  29.       Writeln(' exists.') else
  30.       Writeln(' does not exist.');
  31.       Writeln;
  32.    Until FileName = 'Q';
  33. end.
  34.