views:

39

answers:

1

I have an ASP.NET MVC site that uses both Microsoft Ajax [Ajax.BeginForm()] and jQuery to make asynchronous requests. I want to configure both frameworks such that a generic error handler is automatically attached if the developer does not explicitly specify a failure callback.

In jQuery I can accomplish this with either .ajaxSetup() or .ajaxError(). What is the equivalent in the Microsoft Ajax client library? I'm fairly sure it's something in the Sys object but I can't find it...

A: 

You can check the client events of the PageRequestManager object. The equivalent of ajaxError seems to be endRequest whereas the equivalent of ajaxSetup should be initializeRequest

korchev