Advertisement
believe_me

Untitled

May 17th, 2022
2,094
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function isFileEmpty(): Boolean;
  2. var
  3.     SourceFile: TBinaryFile;
  4.     IsEmpty: boolean;
  5.     SizeOfFile: integer;
  6. begin
  7.     assign(SourceFile, getCurrentDir + '\' + FILE_NAME);
  8.     Reset(SourceFile);
  9.     SizeOfFile := FileSize(SourceFile);
  10.     close(SourceFile);
  11.     Result := (SizeOfFile = 0);
  12. end;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement