FW_ObjMgr_GetObjectInstance

This function returns an interface pointer to an object instance specified by means of object ID.
Return value
FW_ObjMgr_GetObjectInstance : HRESULT;
Name | Type | Description |
---|---|---|
FW_ObjMgr_GetObjectInstance | HRESULT | Returns S_OK if the function call was successful. |
Inputs
VAR_INPUT
oid : OTCID; (*OID of object*)
iid : IID; (*requested interface*)
pipUnk : POINTER TO ITcUnknown;
END_VAR
Name | Type | Description |
---|---|---|
oid | OTCID | Object ID |
iid | IID | Specifies the interface ID to which an interface pointer should be referenced. |
pipUnk | POINTER TO ITcUnknown | Returns the interface pointer to the created object. |
![]() | Necessary release of the interface pointers All references must be explicitly released again. It is recommended to use FW_SafeRelease in order to perform a release of the interface pointer after use. Frequently the release of the references is implemented in the destructor of the object. |
Requirements
TwinCAT Version | Hardware | Libraries to be integrated |
---|---|---|
TwinCAT 3.1, Build 4020 | x86, x64, ARM | Tc3_Module |