dispose object
Published: 31. October 2011 | Updated: 31. October 2011License: Microsoft Public License (MS-PL)
Categories: Framework » Basics
Tags: Basics C# Design Patterns
using (Stream stream = File.Open("...", FileMode.Open)) { // ... } // in the end of a using statement is object disposed // or Stream stream = File.Open("...", FileMode.Open); stream.Dispose();
| Send us feedback about this snippet » |





