Skip to main content
Version: 7.9

system.opc.browseServer

This function is used in Python Scripting.

Description

When called from a Vision Client, returns a list of OPCBrowseElement objects for the given server. Otherwise returns a list of OPCBrowseElements.

The OPCBrowseElement object has the following methods:

  • getDisplayName() - returns the display name of the object
  • getElementType() - returns the element type. Element types are server, device, view, folder, object, datavariable, property and method.
  • getNodeId() - returns a string representing the server node ID

The PyOPCTag object has the following methods to retrieve information:

  • getDisplayName() - returns the display name of the object
  • getElementType() - returns the element type. Element types are server, device, view, folder, object, datavariable, property and method.
  • getServerName() - returns the server name as a string.

Client Permission Restrictions

This scripting function has no Client Permission restrictions.

Syntax

system.opc.browseServer(opcServer, nodeId)

Parameters

TypeParameterDescription
StringopcServerThe name of the OPC server connection.
StringnodeIdThe node ID to browse.

Returns

List - A list of PyOPCTag objects.

Scope

Gateway

Syntax - Vision Client Scope

system.opc.browseServer(opcServer, nodeId)

Parameters

TypeParameterDescription
StringopcServerThe name of the OPC server connection.
StringnodeIdThe node ID to browse.

Returns

List - A list of OPCBrowseElement objects.

Scope

Client

Code Examples

Code Snippet
# Print the name of all devices on Ignition OPC-UA
opcServer="Ignition OPC-UA Server"
nodeId = "Devices"
devices = system.opc.browseServer(opcServer, nodeId)
for device in devices:
print device.getDisplayName()