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...


Where does the dispose method lie and how can it be used to
clean up resources?

Answers were Sorted based on User's Feedback



Where does the dispose method lie and how can it be used to clean up resources? ..

Answer / mohan kumar e.

The dispose method is available in System.IDisposable
interface.If you want to provide cleanup mechanism then
implement this interface and provide the definition for
dispose() method.

Is This Answer Correct ?    2 Yes 0 No

Where does the dispose method lie and how can it be used to clean up resources? ..

Answer / rutu

Dispose() is available in System.IDisposable interface.
Microsoft has suggested two methods that can be invoked by
the programmer for the release of resources i.e Close() and
Dispose().
If any of the method is invoked by the programmer before
loosing the reference to an object, care must be taken to
avoid finalze() to be invoked on the same object when it is
garbage collected and we can do this using
GC.SuppressFinalise().

Public Sub Dipose()' or Close()
'write code here to release the resources
GC.SuppressFinalize(Me)
End Sub

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Sharp Interview Questions

When Should You Call The Garbage Collector In .net?

0 Answers   Siebel Systems,


What is stringreader in c#?

0 Answers  


What is int32?

0 Answers  


What is the difference between the debug class and trace class? Documentation looks the same.

0 Answers  


Describe two uses of the “using” statement during the operation of c#?

0 Answers  


What is a Command Object in C#?

0 Answers   B-Ways TecnoSoft,


Can we overload the main method in c#?

0 Answers  


What is a proxy of the server object in .NET Remoting?

1 Answers   BirlaSoft,


In the page load event I assigned dropdownlist’s datasource property to a valid list. On the submit button click.. The same datasource property is coming as null. Why?

0 Answers  


What is the main method?

0 Answers  


Explain namespaces in c#.

0 Answers  


What is the difference between static and private constructor in c#?

0 Answers  


Categories