title: Map entity to JSON using JavaScriptSerializer
body: <p>My entities are like this:</p>
  
  <pre><code>class Address
  {
       public string Number { get; set; }
       public string Street { get; set; }
       public string City { get; set; }
       public string Country { get; set; }
  }
  
  class Person
  {
       public string Name { get; set; }
       public int Age { get; set; }
       public Address PostalAddress { get; set; }
  }
  
  Person newPerson = 
      new Person()
      {
         Name = "Kushan",
         Age = 25,
         PostalAddress = 
             new Address()
             {
                 Number = "No 25",
                 Street = "Main Street",
                 City = "Matale",
                 Country = "Sri Lanka"
             }
      };
  </code></pre>
  
  <p>Now I wanna map this newPerson object into JSON object like this,</p>
  
  <pre><code>{ 
       "PER_NAME" : "Kushan",
       "PER_AGE" : "25",
       "PER_ADDRESS" : {
                            "ADD_NUMBER" : "No 25",
                            "ADD_STREET" : "Main Street",
                            "ADD_CITY" : "Matale",
                            "ADD_COUNTRY" : "Sri Lanka"
                       }
  }
  </code></pre>
  
  <p>Note: Above is just an example.</p>
  
  <p>What I need is, I need to customize the Key at the serializing time. by default it is taking property name as the key. I can't change property names. How to do this?</p>
  
  <p>Also, is it possible to change to order of appearing key-value pairs in JSON obj.?</p>