What protocol are you using to download the file? Both http and ftp are
capable of resuming downloads - or is this a custom protocol? The
answers to these questions will help you get a proper answer...
Ok... You'll want to use the HttpWebRequest.AddRange method before you
try and resume the download... You'll look at how many bytes your
recieved and want to start at the next byte. So say you got 50 bytes of
a 100 byte file... you would call:
' - indicates from this position to end of data
myWebRequest.AddRange (-51)
Does that make sense? You are basically setting the HTTP Range header.
OK. Thanks, but I need to keep the file as a byte array & then open it from
the next byte I think. How do I do about doing all this (code sample please)?
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.