Re: Resuming ftp upload

Giganews Newsgroups
Subject: Re: Resuming ftp upload
Posted by:  Remy Lebeau (TeamB) (no.spam@no.spam.com)
Date: Mon, 21 Mar 2005

"Antti Kurenniemi" <NOant…@SPAManttikPLEASE.com> wrote in message
news:316D741520C4E240NOant…@SPAManttikPLEASE.com...

>  IdFTP.Put(TempFile, ExtractFileName(TempFile), True)

You cannot use that version of Put() for resumed uploads.  You need to use
the version of Put() that takes a TStream/TIdStreamVCL instead.  This is
required because you need to manually seek the source file to the position
of resume before you upload it.  If you do not do this, then the file on the
client side is always sent from the beginning, but the file on the server
end is appended from the end of file, so the file on the server end will be
corrupted.

Gambit

Replies

In response to

Resuming ftp upload posted by Antti Kurenniemi on Tue, 22 Mar 2005