dOPC Client Toolkit
Close
dOPCDA.TdOPCItem.ItemID

Identifier for OPC items

property ItemID: string;
__property AnsiString ItemID;

To identify OPC Items the TdOPCDAClient works with unique ItemIds. The ItemId is a string. 

Here an example how to add an ItemId to a OPC group:

G.OPCItems.AddItem('Random.String');

In OPC UA, every entity in the address space is a unique node. 

Each node has a NodeId object, which is has 3 properties: 

 

Property
NamespaceIndex
The namespace index as a number. Default is 0.
IdentifierType
The data type of the identifier. Default is string
Identifier
The identifier for a node.

Following Identifier types are supported:

IdentifierType
character
number
i
string
s
globally unique identifier (GUID)
g
opaque value (ByteString)
b

To convert a NodeId object to a string based ItemId you have to use following format:

ItemId := ns=<NamespaceIndex>;<Identifiertype>=<Identifier>

Examples:

G.OPCItems.AddItem('ns=0;i=2256'); // NodeId with IdentifierType i = number and NamespaceIndex = 0 G.OPCItems.AddItem('ns=5;s=Random1'); // NodeId with IdentifierType s = string and NamespaceIndex = 5
Kassl GmbH Copyright © 2024. All rights reserved.