code_junkie

How do I stop the Invalid Length warning in Selenium from occuring?

Nov 12th, 2011
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. Response.ClearContent();
  2. string data = GetSomeData();
  3. Response.Write(data);
  4. Response.Flush();
  5. Response.Close();
  6.  
  7. Response.AddHeader("Content-Length", data.Length.ToString());
  8.  
  9. Response.ClearContent();
  10. string data = GetSomeData();
  11. Response.AddHeader("Content-Length", data.Length.ToString());
  12. Response.Write(data);
  13. Response.Flush();
  14. Response.Close();
Add Comment
Please, Sign In to add comment