hello everyone..i'm trying to get a file in a server using a WebRequest..the server sends some headers saying "Transfer-Encoding :chunked"..what does this basically mean??? I'm using a BinaryReader to read the data..but after some few hundred bytes the transfer just stops..do i have to make a WebRequest again to get the remaining portion of the file??? Please help.
cool_zephyr
7
Junior Poster in Training
Recommended Answers
Jump to PostTry this:
http://blog.degree.no/2011/06/webclient-httpwebresponse-problems-with-chunked-transfer-encoding/... which says:
The easiest way to fix this is to make sure the HttpWebRequest is sent using HTTP 1.0 - this way the server will reply with a HTTP Header specifying Content-Length.
HttpWebRequest wr = (HttpWebRequest)WebRequest.Create("
Jump to Post...not sure. Is your download coming to you with the wrong encoding?
Jump to PostDid you open a stream?
like:
protected static Stream GetRepsonseStream(string strURI) { HttpWebRequest req = (HttpWebRequest)HttpWebRequest.Create(strURI); req.ProtocolVersion = HttpVersion.Version10; return req.GetResponse().GetResponseStream(); }
Also, if you did, I saw this post on keeping the sample rate low
Jump to PostRight. Do you have a URI to the actual stream?
All 15 Replies
thines01
401
Postaholic
Team Colleague
Featured Poster
cool_zephyr
7
Junior Poster in Training
thines01
401
Postaholic
Team Colleague
Featured Poster
cool_zephyr
7
Junior Poster in Training
thines01
401
Postaholic
Team Colleague
Featured Poster
cool_zephyr
7
Junior Poster in Training
thines01
401
Postaholic
Team Colleague
Featured Poster
cool_zephyr
7
Junior Poster in Training
thines01
401
Postaholic
Team Colleague
Featured Poster
cool_zephyr
7
Junior Poster in Training
thines01
401
Postaholic
Team Colleague
Featured Poster
cool_zephyr
7
Junior Poster in Training
thines01
401
Postaholic
Team Colleague
Featured Poster
cool_zephyr
7
Junior Poster in Training
thines01
401
Postaholic
Team Colleague
Featured Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.