If I have code like
try
{
return;
}
catch
{
return;
}
finally
{
return;
}
from which block will the value will be returned. and try
has been executed without any error.
Answer Posted / claivan
Finally block will not return any values as it gives
error "Control cannot leave the body of a finally clause".
The finally block is useful for cleaning up any resources
allocated in the try block.
Is This Answer Correct ? | 13 Yes | 0 No |
Post New Answer View All Answers
What is the difference between ienumerable and icollection?
What are the Types of instancing properties and explain each. Explain the difference between multiuse,singleuse and globalmultiuse and which is default
What is the purpose of static?
Can abstract class have constructor c#?
What is hashtable c#?
What is Satellite Assemblies ?
What is generic types in c#?
What is a web service in c#?
What is c# used for?
Does console.writeline() stop printing when it reaches a null character within a string?
What is the use of command builder?
What is difference between singleordefault and firstordefault?
Are string objects mutable or immutable?
Explain the 3 types of properties in c# with an example?
What does writeline mean?