title: How get filesize in cross-platform way on delphi xe2
body: <p>I have this rutine to know the filesize:</p>
  
  <p>(Based on <a href="http://delphi.about.com/od/delphitips2008/qt/filesize.htm" rel="noreferrer">http://delphi.about.com/od/delphitips2008/qt/filesize.htm</a>)</p>
  
  <pre><code>function FileSize(fileName : String) : Int64;
  var
    sr : TSearchRec;
  begin
    if FindFirst(fileName, faAnyFile, sr ) = 0 then
    {$IFDEF MSWINDOWS}
       result := Int64(sr.FindData.nFileSizeHigh) shl Int64(32) + Int64(sr.FindData.nFileSizeLow)
    {$ELSE}
       result := sr.Size
    {$ENDIF}
    else
       result := -1;
  
    FindClose(sr) ;
  end;
  </code></pre>
  
  <p>However, this give this warning:</p>
  
  <pre><code>[DCC Warning] Funciones.pas(61): W1002 Symbol 'FindData' is specific to a platform
  </code></pre>
  
  <p>I wonder if exist a clean cross-platform way to do this. I check TFile class and not found it...</p>