System.Win.ComObj.TComObjectFactory.CreateComObject

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

function CreateComObject(const Controller: IUnknown): TComObject; virtual;

C++

virtual TComObject* __fastcall CreateComObject(const System::_di_IInterface Controller);

Properties

Type Visibility Source Unit Parent
function public
System.Win.ComObj.pas
System.Win.ComObj.hpp
System.Win.ComObj TComObjectFactory

Description

Instantiates a TComObject object.

CreateComObject is the method that instantiates the class type for which TComObjectFactory is the class factory. CreateComObject calls the CreateFromFactory constructor of the TComObject class to create a COM object. CreateComObject passes itself as the Factory parameter to CreateFromFactory.

CreateComClass creates a COM object based upon the value of the ComClass property. ComClass is the class identifier (CLSID) used by other applications to identify the COM class for which they request an object instance.

See Also