Skip to main content

TcxOwnedInterfacedPersistent.QueryInterface(TGUID,Untyped) Method

Provides access to the implementation of the specified interface if the current persistent property set or information container supports it.

Declaration

function QueryInterface(const IID: TGUID; out Obj): HRESULT; virtual; stdcall;

Parameters

Name Type
IID TGUID
Obj

Returns

Type
HRESULT

Remarks

Call this function and pass a supported interface’s globally unique 128-bit identifier (GUID) as the IID parameter to obtain a reference to the interface implementation via the Obj parameter. The function returns 0, internally calls the _AddRef function, and creates a new reference to a TcxOwnedInterfacedPersistent class descendant instance, provided that the class implements the interface; otherwise, the QueryInterface function returns the cxE_NOINTERFACE global constant.

See Also