How to pass int values to asp.net page methods from jquery?

Posted by Pandiya Chendur on Stack Overflow See other posts from Stack Overflow or by Pandiya Chendur
Published on 2010-03-30T04:03:45Z Indexed on 2010/03/30 4:13 UTC
Read the original article Hit count: 216

Filed under:
|
|

I am using asp.net page methods with jquery..... Here is my code,

$.ajax({
      type: "POST",
      url: "Default.aspx/GetRecords",
      data: "{}",
      contentType: "application/json; charset=utf-8",
      dataType: "json",

and asp.net page method is,

[WebMethod]
public static string GetRecords(int currentPage,int pagesize)
{
    // my logic here
}

How to pass values for currentPage and pagesize from jquery....

© Stack Overflow or respective owner

Related posts about jQuery

Related posts about ASP.NET