[
  {
    "Id": "224021",
    "ThreadId": "65854",
    "Html": "<p>Hi again,</p>\r\n<p>When I use the GZipStream.CompressString under WM5/CF2 i got TypeLoadException.</p>\r\n<p>I use the following code under regular enviroment and under CF.&nbsp; The&nbsp;regular test pass succefully, the CF test gave me the TypeLoadException exception.</p>\r\n<p>public bool CompressTest()<br>{<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; bool bResult = false;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; try<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; string s1 = &quot;abcde 12345 abcde 12345 abcde 12345 abcde 12345&quot;;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //StringBuilder sb = new StringBuilder();<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //for (int i = 0; i &lt; 200; i++)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //&nbsp;&nbsp;&nbsp; sb.Append(s1);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //s1 = sb.ToString();<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; byte[] ba = GZipStream.CompressString(s1);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; string s2 = GZipStream.UncompressString(ba);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; bResult = s1 == s2;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; catch (Exception ex)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; MessageBox.Show(ex.Message + &quot;\\nstack trace=\\n&quot;+ex.StackTrace);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return bResult;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>}</p>\r\n<p>&nbsp;</p>\r\n<p>When I took the code of the CompressString from <a href=\"http://dotnetzip.codeplex.com/Thread/View.aspx?ThreadId=65306\">http://dotnetzip.codeplex.com/Thread/View.aspx?ThreadId=65306</a>, i saw that the Exception raise on the constructor of GZipStream.</p>\r\n<p>Did I miss something?</p>\r\n<p>&nbsp;</p>\r\n<p>&nbsp;</p>",
    "PostedDate": "2009-08-16T06:48:22.363-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "224067",
    "ThreadId": "65854",
    "Html": "<p>Can you give me the stacktrace?</p>\r\n<p>The last time someone reported an exception on WM5, it was within the GZipStream constructor, and it occurred because the install of WM5 did not have the iso-8859-1 code page built in.&nbsp;&nbsp; You can <a href=\"http://dotnetzip.codeplex.com/Thread/View.aspx?ThreadId=65316\">read about that prior case</a>.&nbsp; Could that be possible in your case?</p>\r\n<p>The full stacktrace would likely give us some input.&nbsp;</p>\r\n<p>&nbsp;</p>",
    "PostedDate": "2009-08-16T12:52:01.507-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "224201",
    "ThreadId": "65854",
    "Html": "<p>The stacktrace end with the call to the CompressTest(), no additional info.</p>\r\n<p>I try to compress simple text. no special chars or compressed format. i'm not sure it the same case.</p>\r\n<p>The problem is with the WM5/6 enviroment? (i'm using WM6, not WM5. my mistake ...). I'll try to test it on a CE5 device (it won't help me much, but maybe it can lead us to somewhere&nbsp;...)</p>\r\n<p>&nbsp;</p>\r\n<p>&nbsp;</p>\r\n<p>&nbsp;</p>",
    "PostedDate": "2009-08-17T02:54:18.947-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  },
  {
    "Id": "224472",
    "ThreadId": "65854",
    "Html": "<p>right, well stacktraces normally DO end with the call you've just made.&nbsp; The question is, what are the other methods on the stack?&nbsp;</p>\r\n<p>The problem I referenced was not related to special characters.&nbsp;&nbsp; Read about it and you'll see.</p>\r\n<p>You said you weren't sure that it was the same case. Neither am I; the stacktrace would probably tell us.</p>\r\n<p>&nbsp;</p>\r\n<p>&nbsp;</p>",
    "PostedDate": "2009-08-17T07:57:00.597-07:00",
    "UserRole": null,
    "MarkedAsAnswerDate": null
  }
]