How do i read javascript array in c sharp
<p>I have created a function in javascript like a class</p>

<pre><code> function myclass
{
this.Id=null;
this.Name=null;
}
</code></pre>

<p>from other function i am returning a list(Array in javascript) of myclass  </p>

<pre><code>function ReturnList
{
   var lst=[];
   var objmyclass=new myclass();
   objmyclass.Id=1;
objmyclass.Name="abc";

var objmyclass1=new myclass();
   objmyclass1.Id=1;
objmyclass1.Name="abc";

lst.push(objmyclass);
lst.push(objmyclass1);

PageMethods.GetListData(lst,onsuccess);

return false;
}
</code></pre>

<p>How do i read the lst in my webmethod</p>

<pre><code>[WebMethod()]
public static bool GetListData(datatype lst)
{
   //How to read each item from lst
}
</code></pre>
