If all code is written in a try block and write a catch
block with Exception type Exception .In that scenario will
all the exceptions catched by that catch block? or any
exceptions which will not be caught?
Answer Posted / pompana gouda
Yes and No is the answer...
Yes because, Any type of exception will be caught by general
catch block.
No because,
If there are 3 lines which generate 3 different exceptions,
Then only first exception is caught in the general exception
catch block. If first line is not throwing exception then
whatever the line which throws exception will be caught...
Not all exceptions are handled by single catch statement.
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
How can I produce an assembly?
Differentiate between copy and default constructor.
What is a ienumerator?
What are access modifiers used for?
Is post back c#?
What is the difference between C# 3.5 and C# 4.0?
Overloaded constructor will call default constructor internally?
What is console writeline in c#?
What is the usage of transponders?
What is difference between for and foreach in c#?
What is activator c#?
Explain how to implement delegates in c#.net
What are custom attributes in c#?
What is the use of delegates in c#?
What is default value of decimal c#?