function FileSize(FileName: string):Integer;<br>var<br> TH: THandle;<br> TF: TWin32FindData;<br>begin<br> TH:= FindFirstFile(PChar(FileName), TF);<br> if TH <> INVALID_HANDLE_VALUE then<br> begin<br> Windows.FindClose(TH);<br> Result:= TF.nFileSizeLow;<br> end else Result:= 0;<br>end;<br>