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
What are different methods of session maintenance in asp.net?
How can you register a custom server control to a web page?
how can create login from create and written conde in asp.net
Do you know caching feature?
What is the difference between Session and response.Redirect?
How does session authentication work?
Define application state variable and session state variable?
What is asp.net web application?
Whats the difference between abstract factory pattern and factory pattern?
What is difference between session and viewstate?
What are directives in asp.net? List down all the important directives.
What is an assembly? Explain its parts.
What is state management technique?
What types of data validation events are commonly seen in the client-side form validation?
Dataset is the disconnected environment. suppose if you are binding records to gridview (disconnected environment) and you are making changes to the the grid but before updating the database if any other user modify the data, how will you avoid such problem?