If we write a goto or a return statement in try and catch
block will the finally block execute?
Answer Posted / om namo bagavathe vasudevaya n
what ever goto or continue statement you used in try/catch
the finally bolck must be executed
even an exception occuerd or an exception not occured in the
try block the finally block defanetly executed
but they are some excptions like system exceptions and
application exceptions.For this exceptions the finally block
may or may not excute because
SYSTEM EXCEPTIONS:this excptions occur during runtime
examples:some hardware problems
Application Exception:they also probally occur whill the
application is running
example:if we give textbox maximum size limt as 50
characters.If we enter morethan 50 characters then some
exceptions should occur
| Is This Answer Correct ? | 13 Yes | 2 No |
Post New Answer View All Answers
What is dynamic in c#?
Is datetime a value type in c#?
What is constructors, explain with syntax
Can constructor be private c#?
What is session and cookies in c#?
What is public, private, protected, internal and internal protected?
What is the importance of closing an ado.net application?
What is the difference between yield and return?
What is the use of 'as' Keyword in C# ?
Can you change the value of a constant filed after its declaration?
Is lazy thread safe c#?
Explain the Usage of web.config
Is c# substring zero based?
What is encapsulation in csharp?
What is ilasm.exe used for?