title: Limitations retrieving JSON String from web service using MonoTouch
body: <p>I am developing an iOS Application using MonoTouch. The application collects its data from a web service, using this code:</p>
  
  <pre><code>private static string getResult (string url)
          {
              string result;
              var request = HttpWebRequest.Create (url);
              request.ContentType = "application/json";
              request.Method = "POST";
  
  
              using (HttpWebResponse response = request.GetResponse() as HttpWebResponse)
              {
                  if (response.StatusCode != HttpStatusCode.OK)
                      Console.Out.WriteLine("Error fetching data. Server returned status code: {0}", response.StatusCode);
                  using (StreamReader reader = new StreamReader(response.GetResponseStream()))
                  {
                      result = reader.ReadToEnd();
                  }
              }
  
              return result;
          }
  </code></pre>
  
  <p>And this works fine, BUT when the json string returned from the Web Service reaches a certain size, the request returns with Internal server error 500. I have tried to invoke the service method directly in a web browser, and this returns a json string as expected. Why will it not work with my code, and is there a way to fix this? </p>
  
  <p><strong>Update:</strong>
  I think this might solve my problem: <a href="http://forums.iis.net/t/1176077.aspx/1" rel="nofollow">http://forums.iis.net/t/1176077.aspx/1</a></p>