Showing posts with label datatable. Show all posts
Showing posts with label datatable. Show all posts

Saturday, March 24, 2012

want to pass datatable (.net) to javascript function

hello,

i have a datatable stored at page level (in aspx). i am binding this datatable to gridview object which has a checkbox column for row selection.this table may contain about 500 to 1000 records. when ever i check/uncheck this checkbox, i want to update this bound datatable without posting back to server.is it possible through ajax/javascript ?

pl. provide solution for this asap...

Jayesh Shah

You will have to post back to the server if you want to update the DataTable as that is a server side object. However, you could use a UpdatePanel around the GridView to hide the fact that a full postback is occurring.

Wednesday, March 21, 2012

Web Methodst that returns DataTable gives me exception error " "circular reference was det

Hello,

I am getting this error "circular reference was detected while serializing an object of type". The Method GetRecords() is a function that returns DataTable type.. It happens the same thing when i return DataSet as well.

Any help?

Thanks

function GetStatusRecord() {

// Invoke the Echo method on the server.

PageMethods.GetRecords('1', onComplete);

debugger;

// Callback function.

function onComplete(result) {

// Display the echoed string.

alert(result);

}

returnfalse

}

The latest version of Asp.net Ajax no longer allows to serialize DataTable and DataSet anymore.


you are probably right, i havent updated asp.net ajax for about 6 months.