---
title: "What is purpose of dispose method"  
description: "What is purpose of dispose method"  
author: "Anupam Mishra"  
published: 2016-02-08  
updated: 2016-02-11  
canonical: https://www.mindstick.com/forum/33965/what-is-purpose-of-dispose-method  
category: "c#"  
tags: ["c#", "asp.net"]  
reading_time: 1 minute  

---

# What is purpose of dispose method

Hi Everyone,I want to know what is [purpose of dispose method](https://www.mindstick.com/interview/23368/what-is-the-purpose-of-dispose-method) and which [scenario](https://yourviews.mindstick.com/view/81221/sports-will-change-the-education-scenario) we used? Can [anyone give me](https://answers.mindstick.com/qa/41194/can-anyone-give-me-some-high-and-low-points-of-each-of-the-four-first-presidential-administrations) a solution?Thank you.

## Replies

### Reply by John Smith

When we are implementing a Dispose [method](https://www.mindstick.com/forum/166/webservice-method) in my application then it releases unmanaged resource used by my application. The .NET Framework garbage collector does not allocate or release unmanaged memory.

The pattern for disposing an object, referred to as a dispose pattern, imposes order on the lifetime of an object. The dispose pattern is used only for objects that access unmanaged resources, such as file and pipe handles, registry handles, wait handles, or pointers to blocks of unmanaged memory. This is because the garbage collector is very efficient at reclaiming unused managed objects, but it is unable to reclaim unmanaged objects.


---

Original Source: https://www.mindstick.com/forum/33965/what-is-purpose-of-dispose-method

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
