Requirement is:

try
{
\\SQL Query
}
catch(Exception i)
{
print a
}
catch(SQLQueryException e)
{
\\SQL Query
}


Qu)I Got Exception in "try" block. Which "catch" statement
(i.e. 1st catch or 2nd catch ) catches the exception and
Why???

Answer Posted / balakrishnan

The First Catch block will be executed, if the generic
exception should be defined it should be the last of
exception list

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Does razor engine supports for tdd?

935


What is objectset? : Entity framework

749


What are the versions of .net framework?

752


Explain the methods used to render the views in ASP.Net MVC?

866


Explain the use of Inversion of control (IOC)?

804


What is the meaning of unobtrusive javascript?

777


What is .net architecture?

746


Explain what is the difference between view and partial view?

822


What is Area in ASP.Net MVC?

830


Where is the new functionality in the .net framework 3.0 (such as wcf, wf, wpf, and cardspace) installed to? Is that different from where the .net framework 2.0 is installed to?

767


Explain the advantage of packaging over xcopy in .net?

746


What is the full form of sp?

704


Can you explain renderbody and renderpage in asp.net mvc?

767


Explain what is asp.net mvc?

874


Explain two instances where routing is not implemented or required?

818