title: C# problem with big JSON in InnerText of Webbrowser Control
body: <p>I Can't get a big JSON loaded in the Webbrowser Control. Using IE11 and this reg to load the JSON instead of downloading it.</p>
  
  <p><code>[HKEY_CLASSES_ROOT\MIME\Database\Content Type\application/json]
  "CLSID"="{25336920-03F9-11cf-8FD0-00AA00686F13}"
  "Encoding"=hex:08,00,00,00</code> </p>
  
  <p>If I download the file it has 7.329.068 chars. 
  If I load it in webbrowser control (or WebClient) and access webBrowser2.Document.Body.InnerText it has only 2.634.268 chars.</p>
  
  <p>The interesting part is, the file isn't chopped. There are child elements missing in the file.Checked tis in Notepad++.</p>
  
  <p>Biggest problem is, even without the registry workaround and a webclient dowload the file isn't complete. </p>
  
  <p>I have to use webbrowser control because of difficult session handling in this case. JSON is a 1 line file with above 5 millions chars. JSON file is deserialized with JavaScriptSerializer and works perfekt for the given JSON</p>
  
  <pre><code>        private void GetJsonView(string url_)//object sender, EventArgs e)
          {
              webBrowser2.Navigate(new Uri(url_));
              webBrowser2.Navigate(url_);
          }
  
          private void webBrowser2_DocumentCompleted(object sender, WebBrowserDocumentCompletedEventArgs e)
          {
              innerText = webBrowser2.Document.Body.InnerText;
  
              JavaScriptSerializer test = new JavaScriptSerializer();
              test.MaxJsonLength = Int32.MaxValue;
              sicht = test.Deserialize&lt;View&gt;(innerText);
  
          }
  </code></pre>
  
  <p>Workaround instead of registry entry, gives same missing nodes result</p>
  
  <pre><code>        private void webBrowser2_Navigating(object sender, WebBrowserNavigatingEventArgs e)
          {
              if (e.Url.Segments[e.Url.Segments.Length - 1].EndsWith("/"))
              {
                  e.Cancel = true;
                  string filepath = null;
  
                  saveFileDialog1.FileName = e.Url.Segments[e.Url.Segments.Length - 1];
                  if (saveFileDialog1.ShowDialog() == DialogResult.OK)
                  {
                      filepath = saveFileDialog1.FileName;
                      WebClient client = new WebClient();
                      client.DownloadFileCompleted += new AsyncCompletedEventHandler(client_DownloadFileCompleted);
                      client.DownloadFileAsync(e.Url, filepath);
                  }
              }
          }
  
  </code></pre>
  
  <p>For now I have no clue, why IE is 'hiding' some nodes. It doesn't matter if the file is saved or directly parsed as string to my method. Main goal is to receive the whole payload and I have no clue how to achive this.</p>