System.Win.ComObj.TComObject.Destroy
Delphi
destructor Destroy; override;
C++
__fastcall virtual ~TComObject(void);
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
destructor | public | System.Win.ComObj.pas System.Win.ComObj.hpp |
System.Win.ComObj | TComObject |
Description
Disposes of an instance of a COM object.
Do not call Destroy directly in an application. Instead, call Free. Free verifies that the COM object is not nil before it calls Destroy.
Destroy checks to see if the Factory property is nil. If it is nil, then Destroy passes False to the CountObject method of the Factory object's ComServer, allowing the DLL (server) to be unloaded if no more objects are dependent upon the server.