Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Why do we need a finally block in try catch block while
handling exceptions

Answer Posted / linto

For releasing unmanaged related objects from Garbage
collector.While,exception happen,the process flow may be
change.At that situation unmanaged objects like database
connection etc should be close.For that purpose we are
using finally block in try catch block.But,Idisposable is
better in the case of efficiency.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is a destructor?

990


What is escape sequence in c#?

1017


What is the difference between array and arraylist in c#?

1044


How do you type a null character?

881


For methods inside the interface why can’t you specify the accessibility modifier?

956


What is a datacontract?

944


What is difference between for and foreach loop in c#?

1026


how to implement a web service in .net

979


Define Abstract Class in C#

972


Explain Constructor and destructor?

969


Why is it not a good idea to use empty destructors?

1046


What is deadlock in c#?

945


Explain the types of comments in c#?

918


What is difference between constants and read-only?

954


Explain About sn.exe

994