ASP PageMethod not working :-/
-
All my AJAX using Page Methods is working except one which just never gets back to client side(but executes and returns fine on server). The only difference between this method and the previous ones is that this one returns a bit more data(all are strings btw). Ive tried making it return an array of sections of the string but it also never comes back. Please help, this is pretty urgent and its making me crazy :-/ Thank you
Strive to be humble enough to take advice, and confident enough to do something about it.
-
All my AJAX using Page Methods is working except one which just never gets back to client side(but executes and returns fine on server). The only difference between this method and the previous ones is that this one returns a bit more data(all are strings btw). Ive tried making it return an array of sections of the string but it also never comes back. Please help, this is pretty urgent and its making me crazy :-/ Thank you
Strive to be humble enough to take advice, and confident enough to do something about it.
You might have forgot to add script manager with EnablePageMethods="true"?
Anurag Gandhi. http://www.gandhisoft.com Life is a computer program and every one is the programmer of his own life.
-
You might have forgot to add script manager with EnablePageMethods="true"?
Anurag Gandhi. http://www.gandhisoft.com Life is a computer program and every one is the programmer of his own life.
No, as I said, all the other ones on the page work. I set a onfail method and it results in "object [object]" ?
Strive to be humble enough to take advice, and confident enough to do something about it.
-
All my AJAX using Page Methods is working except one which just never gets back to client side(but executes and returns fine on server). The only difference between this method and the previous ones is that this one returns a bit more data(all are strings btw). Ive tried making it return an array of sections of the string but it also never comes back. Please help, this is pretty urgent and its making me crazy :-/ Thank you
Strive to be humble enough to take advice, and confident enough to do something about it.
How much more data are we talking here?, the PageMethod could be trying to send too much data to the JavaScript serializer, the default value is 102400 characters but you can change that in the web.config with the following:
<system.web.extensions>
<scripting>
<webServices>
<jsonSerialization maxJsonLength="500000" />
</webServices>
</scripting>
</system.web.extensions> -
How much more data are we talking here?, the PageMethod could be trying to send too much data to the JavaScript serializer, the default value is 102400 characters but you can change that in the web.config with the following:
<system.web.extensions>
<scripting>
<webServices>
<jsonSerialization maxJsonLength="500000" />
</webServices>
</scripting>
</system.web.extensions>Thanks :D
Strive to be humble enough to take advice, and confident enough to do something about it.