Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET Ajax
Hi All,
How can I create Global Error Handler for Static Page Methods?
Thanks,
Posted 3-Jan-13 8:05am

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

A global error handler on a website will be called for all pages. It has nothing to do with AJAX, unless you mean the AJAX methods being called on the server are static ( they don't need to be ). What makes you think static methods are ignored ?
  Permalink  
Comments
zeeShan anSari at 3-Jan-13 14:16pm
   
let's suppose there are many PageMethods in different pages of website. But now i want make a generic exception handler because i don't want change in my code. Like as function endRequest(sender, args) for PageRequestManager.
Christian Graus at 3-Jan-13 14:19pm
   
Your global.asax has exactly a method like that, to handle exceptions across the site.
zeeShan anSari at 3-Jan-13 14:22pm
   
no global.asax can't catch the error in pagemethod.
Marcus Kramer at 3-Jan-13 15:12pm
   
Yes, global.asax is set up to do exactly that.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Maciej Los 200
1 Kornfeld Eliyahu Peter 175
2 BillWoodruff 160
3 George Jonsson 140
4 OriginalGriff 126


Advertise | Privacy | Mobile
Web04 | 2.8.141015.1 | Last Updated 3 Jan 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100