www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - Delete COM object

reply Heinz <malagana15 yahoo.es> writes:
Hello everyone,

Whenever i try to explicity delete a COM object (clases and interfaces
inherited from IUnknown) i get compiler errors.
How can i delete a COM object to free memory?

I create objects inside a loop, and so memory usage keeps growing as i can't
delete objects or set them to null.
Jun 04 2008
parent John C <johnch_atms hotmail.com> writes:
Heinz Wrote:

 Hello everyone,
 
 Whenever i try to explicity delete a COM object (clases and interfaces
inherited from IUnknown) i get compiler errors.
 How can i delete a COM object to free memory?
 
 I create objects inside a loop, and so memory usage keeps growing as i can't
delete objects or set them to null.
You don't delete COM objects - you call their Release() method.
Jun 04 2008