.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
david stephan

Home >> Interview Question >> C# >> Post New Question Subscribe to Interview Questions

Will finally block get executed if the exception had not occurred?

Posted By :Ghanashyam Nayak     Posted Date :September 09, 2010    Points :10   Category :C# 
Yes

You can also find related Interview Question to Will finally block get executed if the exception had not occurred?  below: 

Can code inside multiple catch block be executed?

  
No, Code can not execute in mutiple catch block (More...)

Why do we need Try-Finally block?

  
The code inside the finally block will be executed even after throwsing the exception, and the statements in the program that followed th finally block will not be executed.

Thus the exception prevents the control from beign transfered to any part of the program execept th finally block. (More...)

Why is catch(Exception) almost always a bad idea?

  
Well, if at that point you know that an error has occurred, then why not write the proper code to handle that error instead of passing a new Exception object to the catch block? Throwing your own exceptions signifies some design flaws in the project. (More...)

Can multiple catch blocks be executed for a single try statement?

  
No. Once the proper catch block processed, control is transferred to the finally block (if any).

So we can not execute multiple catch block in one try block (More...)

Suppose you want a certain ASP.NET function executed on MouseOver for a certain button. Where do you add an event handler?

  
Add an OnMouseOver attribute to the button. Example: btnSubmit.Attributes.Add("onmouseover","someClientCodeHere();"); (More...)

What is TCB(Transmission Control Block)?

  
A TCB is a complex data structure that contains informations about each connection. (More...)

Which class is the base class of all the exception classes?

  
System.Exception class is the base class of all the exception classes in .NET. (More...)

Which namespace is used to create an Exception Tree?

  
System.Data.Common.CommandTree namespace provide classes to create an Exception Tree. (More...)

Which contract is used to documented the view for error occurred in the service to client in wcf?

  
Fault Contract is used to documented the view for error occurred in the service to client in wcf (More...)

Quick Links For Interview Questions Categories:
ASP.Net Windows Application   .NET Framework   C#   VB.Net   ADO.Net  
Sql Server   SharePoint   Silverlight   OOPs   JQuery   JavaScript/VBScript
Biztalk Patten/Practices .IIS WCF WPF WWF
Networking Aptitude Others   All      

Find questions, FAQ's and their answers related to .NET, C#, Vb.Net, Sql Server and many more.

 
Now you can find lots of .NET, C#, Vb.Net, SQL Server,Windows, ASP.Net related Questions and their Answers here at www.dotnetspark.com. Our aim is to help you pass your certification Exams (MCP, MCSD, MCAD etc.,) with flying scores and get good name in your company.

So, Start looking our Interview Question section daily and improve your .NET Skills. You can also help others by posting Interview Questions and their Answers in this section.


Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend