title: JavaScriptSerializer.Deserialize array
body: <p>I'm having trouble deserializing an array in .NET MVC3, any help would be appreciated.</p>
  
  <p>Here's the code snippet:</p>
  
  <pre><code>using (HttpWebResponse response = request.GetResponse() as HttpWebResponse)
  using (StreamReader reader = new StreamReader(response.GetResponseStream())) {
      JavaScriptSerializer jsSerializer = new JavaScriptSerializer();
      string jsonData = reader.ReadToEnd();
      result = (BigCommerceOrderProducts)jsSerializer.Deserialize&lt;BigCommerceOrderProducts&gt;(jsonData);
  }
  </code></pre>
  
  <p>Here's the subset of the data string returned by JSON as jsonData. I've remove extra fields. </p>
  
  <pre><code>"[
  {\"id\":33,\"order_id\":230025,...},
  {\"id\":34,\"order_id\":230025,...}
  ]"
  </code></pre>
  
  <p>Here are the objects:</p>
  
  <pre><code>[Serializable]
  public class BigCommerceOrderProducts {
      public List&lt;BigCommerceOrderProduct&gt; Data { get; set; }
  }
  
  [Serializable]
  public class BigCommerceOrderProduct {
      public int Id { get; set; }
      public int Order_id { get; set; }
      ...
  }
  </code></pre>
  
  <p>I'm getting this error:</p>
  
  <pre><code>"Type 'Pxo.Models.BigCommerce.BigCommerceOrderProducts' is not supported for deserialization of an array.
  </code></pre>
  
  <p>Any ideas?</p>