3
Reply

Can multiple catch blocks be executed?

    No, Multiple catch blocks can’t be executed. Once the proper catch code executed, the control is transferred to the finally block and then the code that follows the finally block gets executed.

    Yes

    you can use catch block with specific error type like
    1> for Divide By Zero Exception

    catch (DivideByZeroException) {
    Console.WriteLine(“Not possible to Divide by zero”);
    }

    2> fot Index Out Of Range Exception

    catch (IndexOutOfRangeException) { Console.WriteLine(“Index is Out of Range”);
    }

    you can put this both block below try block at a time.

    Yes you can use multiple catch but one try