Indy 9
Example
TIdFTP.Size
      iSize := AFtp.Size('image.jpg');
      if (iSize <> -1) and (iSize < GetDiskSpace('D:')) then
      AFtp.Get('image.jpg', 'd:tempimage.jpg', True);

Created with Doc-O-Matic 2 donated to Project JEDI. Commercial license available from the Doc-O-Matic site.