I believe you mean Update Panels when you are talking about Ajax. The Update Panel Framework handles the Page's error event and clears the error. You can alternatively handle the AsyncPostBackError event of the ScriptManager. Unfortunately to handle the event at application level might be tricky. You may have to handle the PreRequestHandlerExecute event and add an handler to the OnInitComplete event to the Page object casted from the Context.Handler object.Then you can get the ScriptManager and you can add the AsyncPostbackError event handler.
This is really unfortunate. It breaks the uniform way of handling errors in HttpApplication.Error event. What was the rationale behind this design decision?
No comments:
Post a Comment