What are the uses of “using” in C#?

The reason for the using statement is to ensure that the object is disposed as soon as it goes out of scope, and it doesn’t require explicit code to ensure that this happens. As in Understanding the ‘using’ statement in C# (codeproject) and Using objects that implement IDisposable (microsoft), the C# compiler converts using (MyResource … Read more