title: Empty JSON objects ([{},{},..]) are written to file
body: <p>im trying to write a simple list to json.</p>
  
  <p>no errors, executes fine but i get this output</p>
  
  <pre><code>[{},{},{}]
  </code></pre>
  
  <p>here is a snippet of my code. studentList is a list of objects of Student class.</p>
  
  <pre><code>    public void jsonRead()
      {
          string json = File.ReadAllText(Environment.CurrentDirectory + @"\JSON.txt");
  
          studentList= new System.Web.Script.Serialization.JavaScriptSerializer().Deserialize&lt;List&lt;Student&gt;&gt;(json);
      }
  
      public void jsonWrite()
      {
  
              string json = new System.Web.Script.Serialization.JavaScriptSerializer().Serialize(studentList);
  
              File.WriteAllText(Environment.CurrentDirectory + @"\JSON.txt", json);
  
      }
  </code></pre>
  
  <p>student class</p>
  
  <pre><code>class Student : IComparable
  {
      private String regID {get;set;}   
      private String name {get;set;}      
      private String address {get;set;}      
      private String gender {get;set;}      
      private Double gpa {get;set;}
  
      public Student()
      {
          regID = null;
          name = null;
          address = null;
          gender = null;
          gpa = 0.0;
      }
      public Student(String regID, String name, String address, String gender, Double gpa)
      {
          this.regID = regID;
          this.name = name;
          this.address = address;
          this.gender = gender;
          this.gpa = gpa;
      }
  
      public void update(String regID, String name, String address, String gender, Double gpa)
      {
          setRegId( regID);
          setName(name);
          setAddress(address);
          setGender(gender);
          setGpa(gpa);
      }
  </code></pre>
  
  <p>followed by setters and getters</p>