How to handle C-sharp exception.
what can i do ,in exception there are three block try,catch,and finally,but i want in my code finally is written but never excuted?
3 Answers
Know the answer? Post it. Somebody with the same question will find it here.


Gopal Mahadak136 reputationPosted Jul 3, 2012, 7:05 PM EDT
so u are not suppose to change its structure...
best way is that don't use finally block after catch block.. it works..
Gopal
Sharad GuptaRank #111 · 20K reputationPosted Jul 4, 2012, 6:37 PM EDT
Jignesh TrivediRank #16 · 50.3K reputationPosted Jul 4, 2012, 7:31 PM EDT
I think,The finally block will not be executed when Exception type is a StackOverflowException because there is no roomto execute more code. It will also not be called when Exception type is an ExecutingEngineException, which is very rare.
so kindly check exception type.
hope this will help you.