title: How to get enum as an json object
body: <p>I have this enum</p>
  
  <pre><code>public enum ComplainStatus
  {           
      Started = 1,    
      Ended = 2,
      Canceled = 3    
  }
  </code></pre>
  
  <p>I need to fill DDL in javascript 
  So I make a Webmethod
  as</p>
  
  <pre><code>[WebMethod]
  public static string getComplainstatus()
  {            
      JavaScriptSerializer TheSerializer = new JavaScriptSerializer();
      string TheJson = TheSerializer.Serialize(ComplainStatus);
      return TheJson;
  }
  </code></pre>
  
  <p>I need to get the enum as an object that can enable me to read it in JS file </p>