GetItemID method

Description
Given a name, returns a valid ItemID that can be passed to OPCItems Add method.
Syntax
GetItemID
(Leaf As String) As String
Leaf
— The name of a BRANCH or LEAF at the current level.
Remarks
The server converts the name to an ItemID based on the current "position" of the browser. It will not correctly translate a name if MoveUp, MoveDown, and so on has been called since the name was obtained.
Example
Dim MyOPCBrowser as OPCBrowser
Set MyOPCBrowser = MyOPCServer.CreateBrowser
'/* Get item information for this branch
MyOPCBrowser.ShowLeafs
For i = 1 to MyOPCBrowser.Count
'/* Display items at this level
lstDisplayItems.Add MyOPCBrowser.GetiItemID(i)
Next 'i
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.
Normal