Hello
Do we need use garbage collector every time when we create unmanaged resources?
Thanks.
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
SenthilkumarPosted Mar 24, 2012, 10:15 PM
The Garbage collection has implemented to manage the auto memory management of manage code, basically it handles the code which runs under the environment of CLR.
I suggest you to go through this example will give more idea about cleaning up unmanaged resources.
http://www.gibmonks.com/c_sharp/csharpckbk2-CHP-3-SECT-31.html
VulpesPosted Mar 24, 2012, 7:35 AM
http://msdn.microsoft.com/en-us/library/system.idisposable.aspx