home *** CD-ROM | disk | FTP | other *** search
/ POINT Software Programming / PPROG1.ISO / pascal / swag / files.swg / 0038_Check for file EXIST.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  1993-09-26  |  634 b   |  17 lines

  1. {*****************************************************************************
  2.  * Function ...... Exist()
  3.  * Purpose ....... Checks for the existance of a file/directory
  4.  * Parameters .... sExp       File/directory name to check for
  5.  * Returns ....... TRUE if sExp exists
  6.  * Notes ......... Not picky, will even accept wild cards
  7.  * Author ........ Martin Richardson
  8.  * Date .......... May 13, 1992
  9.  *****************************************************************************}
  10. FUNCTION Exist( sExp: STRING ): BOOLEAN;
  11. VAR s : SearchRec;
  12. BEGIN
  13.      FINDFIRST( sExp, AnyFile, s );
  14.      Exist := (DOSError = 0);
  15. END;
  16.  
  17.