About 12,200,000 results
Open links in new tab
  1. c# - Catching exceptions with "catch, when" - Stack Overflow

    Jul 21, 2016 · Once that happens, code will resume execution at the "catch". If there is a breakpoint within a function that's evaluated as part of a "when", that breakpoint will suspend …

  2. Can I catch multiple Java exceptions in the same catch clause?

    22 If there is a hierarchy of exceptions you can use the base class to catch all subclasses of exceptions. In the degenerate case you can catch all Java exceptions with:

  3. Difference between catch (Exception), catch () and just catch

    Both constructs (catch () being a syntax error, as sh4nx0r rightfully pointed out) behave the same in C#. The fact that both are allowed is probably something the language inherited from C++ …

  4. Difference between try-finally and try-catch - Stack Overflow

    May 18, 2010 · Finally and catch blocks are quite different: Within the catch block you can respond to the thrown exception. This block is executed only if there is an unhandled …

  5. Why should I not wrap every block in "try"-"catch"?

    37 You don't need to cover every block with try-catches because a try-catch can still catch unhandled exceptions thrown in functions further down the call stack. So rather than have …

  6. Exception handling try catch inside catch - Stack Overflow

    I recently came across code written by a fellow programmer in which he had a try-catch statement inside a catch! Please forgive my inability to paste the actual code, but what he did was …

  7. c# - Catch multiple exceptions at once? - Stack Overflow

    try { WebId = new Guid(queryString["web"]); } catch (FormatException) { WebId = Guid.Empty; } catch (OverflowException) { WebId = Guid.Empty; } Is there a way to catch both exceptions …

  8. python - How can I catch multiple exceptions in one line? (in the ...

    How can I catch multiple exceptions in one line? (in the "except" block) Asked 14 years, 4 months ago Modified 2 months ago Viewed 1.6m times

  9. Catch and print full Python exception traceback without …

    I think that this only works if you raise and then catch the exception, but not if you try getting the traceback before raising an exception object that you create, which you might want to do in …

  10. Exception thrown inside catch block - will it be caught again?

    Sep 27, 2008 · One related and confusing thing to know is that in a try- [catch]-finally structure, a finally block may throw an exception and if so, any exception thrown by the try or catch block …