purosotam gupta
What is the use of DISPOSE method?
By purosotam gupta in .NET on Apr 14 2014
  • Mahaveer Yadav
    Apr, 2014 25

    the dispose method is used to release Unmanaged resourse and to clean up object

    • 1
  • Suresh Logout kiya kar
    Oct, 2015 13

    it is used for cleaning up the unmanaged objects

    • 0
  • Palle Technologies
    Apr, 2014 17

    Using Dispose method of IDisposable interface we can eliminate need of calling Garbage collector for more than one time . When you call Dispose method CLR will give instruction to the operating system which deletes un-managed object which is internally pointed by the managed object . Once CLR gives instruction to the operating system for deleting un-managed object , immediately CLR deletes managed object . For more details you can see what is the use of dispose method in c# in skillgun.com which contains too frequently asked c# interview questions and answers

    • 0
  • Khan Abrar Ahmed
    Apr, 2014 16

    The Dispose method performs all object cleanup, so the garbage collector no longer needs to call the objects' Object.Finalize override. Therefore, the call to the SuppressFinalize method prevents the garbage collector from running the finalizer. If the type has no finalizer, the call to GC.SuppressFinalize has no effect. Note that the actual work of releasing unmanaged resources is performed by the second overload of the Dispose method.

    • 0
  • Munesh Sharma
    Apr, 2014 15

    http://www.dotnet-tricks.com/Tutorial/netframework/P1MK271013-Difference-Between-Finalize-and-Dispose-Method.html

    • 0


Most Popular Job Functions


MOST LIKED QUESTIONS