csharp

I stand on the shoulders of giants or what C# using does

This may be one of the most useful pages explaining "using" in C#.

It seems that
a) Using is a try-finally clause without a catch
b) You must properly implement the IDispose() method, or its magic won't happen.

Now I can use this keyword. I have avoided it because it seems that I don't like magic. Now I will be able to use this construction since I know exactly what it does. Thanks, Peter Femiani , for taking the magic out of "using."

http://www.codeproject.com/KB/cs/CSharp_using.aspx

Syndicate content