Exception Handling with ashx RRS feed

  • Question

  • User-854394800 posted


    I have tried the new GeneratedImage which is based on a HttpHandler. I can't get it to work and the main problem is that I can't really create a good exception handling, thus I don't know what's wrong. I have an ErrorHandling class in which I send all exceptions, and it forwards them into the web server log. Is it possible to access other classes in the project from a HttpHandler class?



    Tuesday, March 10, 2009 6:59 AM

All replies

  • User2032526919 posted

    If those other classes are precompiled, yes it should be possible. If you can't get it to work instantly you can also just add try...catch and let it write the error to the response...at least that helps dbugging at start

    Tuesday, March 10, 2009 7:27 AM
  • User-854394800 posted

     Yeah, I just found out that the communication between the classes worked - it was a cache setting that made the code to never run... There are two cache settings, local and server. How does the code know when to show a cached version of the image, and when to get a new one?



    Tuesday, March 10, 2009 7:45 AM