can we throw execption from catchblock

Answer Posted / praseetha sandeep

yes, we can throw...
catch(Exception e)
{
....
thow e
}

you can also throw new exceptin of different type
catch(IOException c)
{....
throw new FileNotFoundexception(filename)
}

we can also do like
catch(IOException c)
{
throw new FileNotFoundexception(filename,c)
}

Is This Answer Correct ?    6 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the interface in c#?

506


What is data set in c#?

493


What is multidimensional array in c#?

458


Explain copy constructor?

653


Can you explain template pattern?

565






What is strongly typed view?

496


Can interface inherit class in c#?

483


Can arraylist store different data types in c#?

466


What are Types of assemblies that can be created in dotnet

574


What is desktop GUI application?

500


What namespace is list in c#?

485


Write a program to create a user control with name and surname as data members and login as method and also the code to call it. (Hint use event delegates) Practical Example of Passing an Events to delegates

506


Is clr a compiler?

478


How do I run managed code in a process?

497


Explain manifest in c#.

510