Advertisement
cgrunwald

Untitled

Oct 29th, 2010
167
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. Stream resStream = response.GetResponseStream();
  2. StringBuilder sb = new StringBuilder();
  3. byte[] buf = new byte[512];
  4. int count;
  5. do {
  6. count = resStream.Read(buf, 0, buf.Length);
  7. if (count == 0) continue;
  8. string tempString = Encoding.ASCII.GetString(buf, 0, count);
  9. sb.Append(tempString);
  10. }
  11. while (count > 0);
  12. response.Close();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement