dOPC Client Toolkit
Close
dOPCIntf.TdOPCItemData.EUType

EUType contains the type of Engineering Units (EU) information of the item (if any) contained in the property EUInfo.

property EUType: integer;
__property int EUType;
Type
Description
OPC_NOENUM
No EU information available. (EUInfo will be VT_EMPTY)
OPC_ANALOG
EUInfo will contain an array of exactly two doubles (VT_ARRAY | VT_R8). Corresponding to the LOW and HI EU range.
OPC_ENUMERATED
EUInfo will contain a array of strings (VT_ARRAY | VT_BSTR) which contains a list of strings. (Example: OPEN, CLOSE, IN TRANSIT, etc.)
procedure ShowEUInfo(Item: TdOPCItem); var str: string; Low, High: Double; begin case Item.EUType of OPC_NOENUM : str := 'Engineering Units (EU) information not available'; OPC_ANALOG : begin Low := Item.EuInfo[0]; High := Item.EuInfo[1]; str := format('Analog scale from: %.2f to %.2f',[Low,High]); end; OPC_ENUMERATED : str := 'ENUMERATED: ' +VarToAStr(Item.EuInfo); end; ShowMessage(Str); end;
Kassl GmbH Copyright © 2024. All rights reserved.