I am trying to implement a iDisposable class in c# but the examples in msdn and stackoverflow do not works for me.
And im running a console application in visual studio 2012 framework 4.0
am I missing some using or what?
public class Foo : IDisposable
{
public void Dispose()
{
Dispose(true);
GC.SuppressFinalize(this);
}
}
I am following this examples (hyperlinks dont works for me, dont know why):
http://msdn.microsoft.com/en-us/library/ms244737.aspx
Implementing IDisposable correctly
How to implement IDisposable properly