title: Deserialization the json string gives Value cannot be null. Parameter name: s
body: <pre><code>"[{\"active\":true,\"campaignId\":11401,\"createdtime\":1355919181000,\"description\":\"Ankit Demo Edited By Nirav\",\"enddate\":1363132800000,\"groupId\":10179,\"isdeleted\":false,\"lastmodifiedby\":10405,\"modifiedtime\":1362556187000,\"name\":\"Ankit Demo\",\"noofweek\":12,\"organizationId\":11153,\"startdate\":1355875200000,\"status\":2,\"userId\":11161},
  
  {\"active\":true,\"campaignId\":21901,\"createdtime\":1358493958000,\"description\":\"sdadadasd\",\"enddate\":1359072000000,\"groupId\":10179,\"isdeleted\":false,\"lastmodifiedby\":10405,\"modifiedtime\":1358751277000,\"name\":\"NEW CAMP TEST\",\"noofweek\":1,\"organizationId\":10707,\"startdate\":1358467200000,\"status\":4,\"userId\":10405},
  
  {\"active\":true,\"campaignId\":33601,\"createdtime\":1361441582000,\"description\":\"dasdsadasd\",\"enddate\":1363219200000,\"groupId\":10179,\"isdeleted\":false,\"lastmodifiedby\":10405,\"modifiedtime\":1361795632000,\"name\":\"BHAVIK UTC\",\"noofweek\":3,\"organizationId\":10707,\"startdate\":1361404800000,\"status\":2,\"userId\":10405}]"
  </code></pre>
  
  <p>I have Above Jsong String in my string variable ..and i want to convert this json string into an object of my custom class..i have created the custom class ..
  following is the code in which i getingg the response in json from HttpWebResponse and converting in list object of my custom class</p>
  
  <pre><code> HttpWebResponse response = default(HttpWebResponse);
          try
          {
              response = (HttpWebResponse)request.GetResponse();
              //    response.Close()
              string sResult = null;
  
              using (StreamReader responseReader = new StreamReader(response.GetResponseStream()))
              {
                  sResult = responseReader.ReadToEnd();
  
              }
              response.Close();
              Console.WriteLine(sResult);
  
    List&lt;Class1&gt; myDeserializedObjList = (List&lt;Class1&gt;)Newtonsoft.Json.JsonConvert.DeserializeObject(Request[sResult], typeof(List&lt;Class1&gt;));
            int counts=  myDeserializedObjList.Count;
  
          }
  </code></pre>
  
  <p>but its giving me error </p>
  
  <pre><code>Value cannot be null.
  Parameter name: s
  </code></pre>
  
  <p>Can anyone Please guide me how to solve this problem?</p>
  
  <p>this is my custom class to which i want to assign the objects from json string
      using System;
      using System.Collections.Generic;
      using System.Linq;
      using System.Web;</p>
  
  <pre><code>/// &lt;summary&gt;
  /// Summary description for Class1
  /// &lt;/summary&gt;
  public class Class1
  {
  
      private Boolean active;
  
      public Boolean Active
      {
          get { return active; }
          set { active = value; }
      }
      private long campaignId;
  
      public long CampaignId
      {
          get { return campaignId; }
          set { campaignId = value; }
      }
      private long createdtime;
  
      public long Createdtime
      {
          get { return createdtime; }
          set { createdtime = value; }
      }
      private string description;
  
      public string Description
      {
          get { return description; }
          set { description = value; }
      }
      private long enddate;
  
      public long Enddate
      {
          get { return enddate; }
          set { enddate = value; }
      }
      private long groupId;
  
      public long GroupId
      {
          get { return groupId; }
          set { groupId = value; }
      }
      private Boolean isdeleted;
  
      public Boolean Isdeleted
      {
          get { return isdeleted; }
          set { isdeleted = value; }
      }
      private long modifiedtime;
  
      public long Modifiedtime
      {
          get { return modifiedtime; }
          set { modifiedtime = value; }
      }
      private long lastmodifiedby;
  
      public long Lastmodifiedby
      {
          get { return lastmodifiedby; }
          set { lastmodifiedby = value; }
      }
      private string name;
  
      public string Name
      {
          get { return name; }
          set { name = value; }
      }
      private int noofweek;
  
      public int Noofweek
      {
          get { return noofweek; }
          set { noofweek = value; }
      }
      private long organizationId;
  
      public long OrganizationId
      {
          get { return organizationId; }
          set { organizationId = value; }
      }
      private long startdate;
  
      public long Startdate
      {
          get { return startdate; }
          set { startdate = value; }
      }
      private Boolean status;
  
      public Boolean Status
      {
          get { return status; }
          set { status = value; }
      }
      private long userId;
  
      public long UserId
      {
          get { return userId; }
          set { userId = value; }
      }
  
  
  
      public Class1()
      {
  
  
      }
  }
  </code></pre>