title: How to deseralize json object that contains multidimensional array?
body: <p>I need some help about converting JSON object that contains multidimensional array to my class. I tried to deserialize the json object but failed. JsonMaclar class object is null. Please help.</p>
  
  <p>The script code;</p>
  
  <pre><code>var allFields = new Array();
  allFields.push({
                          BirinciKatilimciId: birinciKatilimciId.val(),
                          IkinciKatilimciId: ikinciKatilimciId.val(),
                          BirincininSkoru: birincininSkoru.val(),
                          IkincininSkoru: ikincininSkoru.val(),
                          MacSayisi: macSayisi.val(),
                          MacSuresi: macinSuresi.val(),
                          MacinOynanmaSaati: macinOynanmaSaati.val(),
                          Hukmen: hukmen.is(':checked'),
                          RatingeDahil: ratingeDahil.is(':checked'),
                          MaclarTablosundaGoster: maclarTablosundaGoster.is(':checked'),
                          MacinTarihi: macinTarihi.val()
                      });
  
  $("#&lt;%=btnMaclariKaydet.ClientID %&gt;").click(function () {
  
              var jsonText = JSON.stringify({
                  arrayAllMaclar: allFields
              });
              $('#&lt;%= hfMaclar.ClientID %&gt;').val(jsonText);
  
          });
  </code></pre>
  
  <p>c# code;</p>
  
  <pre><code>protected void btnMaclariKaydet_Click(object sender, EventArgs e)
      {
          JavaScriptSerializer ser = new JavaScriptSerializer();
          JsonMaclar turnuvaMaclar = ser.Deserialize&lt;JsonMaclar&gt;(hfMaclar.Value);
      }
  public class JsonMaclar {
      List&lt;JsonMac&gt; arrayAllMaclar { get; set; }    
  }
  
  public class JsonMac {
      String BirinciKatilimciId { get; set; }
      String IkinciKatilimciId { get; set; }
      String BirincininSkoru { get; set; }
      String IkincininSkoru { get; set; }
      String MacSayisi { get; set; }
      String MacSuresi { get; set; }
      String MacinOynanmaSaati { get; set; }
      String Hukmen { get; set; }
      String RatingeDahil { get; set; }
      String MaclarTablosundaGoster { get; set; }
      String MacinTarihi { get; set; }
  }
  </code></pre>