S
Steve b.
Hi,
I'm building an application that can download resources using HTTP.
In order to enable resuming broken download, I'd like to send to the server
some Http Headers :
string uriString = "http://server/app/resource.ext";
WebRequest req = WebRequest.Create(
uriString
);
req.Headers[HttpRequestHeader.IfRange] = ETag;
req.Headers["Range"] = "1254-";
This code is supposed to resume the download after the 1254th byte.
This code throw an exception when setting the Range header. After some
investigations I found the Range headers is blocked within the .Net
framework.
Firstly, why this header is blocked by the system ?
Then, how can I fix this header ?
Thanks in advance
Steve
I'm building an application that can download resources using HTTP.
In order to enable resuming broken download, I'd like to send to the server
some Http Headers :
string uriString = "http://server/app/resource.ext";
WebRequest req = WebRequest.Create(
uriString
);
req.Headers[HttpRequestHeader.IfRange] = ETag;
req.Headers["Range"] = "1254-";
This code is supposed to resume the download after the 1254th byte.
This code throw an exception when setting the Range header. After some
investigations I found the Range headers is blocked within the .Net
framework.
Firstly, why this header is blocked by the system ?
Then, how can I fix this header ?
Thanks in advance
Steve