Can we throw exception from catch Block?
Answer Posted / devender kumar
Yes. we can throw the exception from the catch block.
If anyone have confusion then try this code:
protected void Button1_Click(object sender, EventArgs e)
{
try
{
Test();
}
catch (Exception ex)
{
Response.Write(ex.ToString());
}
}
private void Test()
{
try
{
throw new Exception("Dev");
}
catch (Exception ex)
{
throw ex;
}
}
| Is This Answer Correct ? | 40 Yes | 2 No |
Post New Answer View All Answers
Explain the code Access Security (CAS) in .net Framework?
Can you explain page lifecycle in net?
How many types of Cookies are available in ASP.NET?
How to use multiple scriptmanager controls in a web page?
What is query string? What are its advantages and limitations?
What is Web API?
Explain what is event bubbling?
What are Caching techniques in .NET
how can we create wcf in asp.net and how can we cll that in to asp.net application?plsss tel me each step clearly
What is difference Between Authentication and authorization?
What is the difference between localization and globalization?
From which base class all web forms are inherited?
What is the difference between a cookie and a pixel?
What is cookies cache and session?
What are the main advantages of using asp.net?