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 / vijay k chin
the above block will not execute as control will be unable to enter in to the filnally block. So return statement should be always in finally block not in the try block.
Is This Answer Correct ? | 1 Yes | 5 No |
Post New Answer View All Answers
Explain how do you convert a value-type to a reference-type?
What is an xsd file?
What is the difference between select and selectmany?
Differentiate between dataset and datareader?
What is strong name in c# and how can we use it?
How to get the sum of last 3 items in a list using lambda expressions?
What is namespace give the example?
What is managed or unmanaged code?
What is the relation between classes and objects?
Explain synchronous and asynchronous operations?
Why singleton class is sealed in c#?
What are assemblies?
What are sessions in c#?
What is the .net datatype that allows the retrieval of data by a unique key?
What is console write in c#?