API | ITcModuleManager 5.31.1 ITcModuleManager | ITcModuleManager Expanded by: ITcModuleManager2 ITcModuleManager is the central access point to the TCom module instances registered in the project. For reasons of binary compatibility, the interface remains IDispatch -based and offers enumeration, OID-based lookup, and online parameter access via ADS. Properties Methods 5.31.1.1 ITcModuleManager::GetOnlineModulePara | ITcModuleManager::GetOnlineModulePara Reads data from the target system via AdsSyncReadReq() . The ADS address uses the document's target NetID and AMSPORT_R0_TCOMSERVER . oid is used as the IndexGroup, and pid is used as the IndexOffset.
If successful, the bytes that were actually read are returned as a byte SAFEARRAY in pvData . Signature HRESULT GetOnlineModulePara(ULONG oid, ULONG pid, ULONG maxData, VARIANT* pvData); Parameter Return value Error codes E_POINTER : pvData is NULL . TE1000 130 Version: 1.7.0 Version Newly introduced Index ITcModuleManager3 Collection view of all module instances (Modules). ITcModuleManager3 Property Type get/set Description ModuleCount LONG* get Number of registered TCom objects. Method Description NewEnum _ Returns a IEnumVARIANT for all TCom objects. LookupModule Searches for a module based on its object ID and returns the requested interface.
GetOnlineModulePara Reads an online parameter via ADS as a byte array. SetOnlineModulePara Writes an online parameter via ADS from a VARIANT. GetOnlineModuleParaDWORD Reads an online parameter as ULONG. SetOnlineModuleParaDWORD Writes an online parameter as ULONG. Name Type Description oid ULONG [in] ADS IndexGroup or object ID of the target module. pid ULONG [in] ADS index offset or parameter ID. maxData ULONG [in] Maximum number of bytes to be read. Name Type Description pvData VARIANT* [out, retval] Bytes read as a byte SAFEARRAY. (HRESULT) HRESULT S OK if successful, otherwise an error code. _