# OpcClient.BrowseNodes Method

> Reference: Browses the nodes as defined by the commands specified to examine their attributes and their references.

<dl class="api-definition">
<dt>Type</dt>
<dd><a href="./">OpcClient</a></dd>
<dt>Namespace</dt>
<dd><a href="../namespaces/opc.uafx.client">Opc.UaFx.Client</a></dd>
<dt>Assembly</dt>
<dd>Opc.UaFx.Advanced.dll</dd>
<dt>Package</dt>
<dd>Opc.UaFx.Advanced v2.59.0</dd>
<dt>Members</dt>
<dd><a href="./members">OpcClient Members</a></dd>
<dt>Also in</dt>
<dd>Opc.UaFx.Client</dd>
</dl>

<span class="api-meta">2 overloads · since v2.9</span>

| Overload | Description |
|---|---|
| [BrowseNodes(IEnumerable&lt;OpcBrowseNode&gt;)](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcclient/browsenodes#browsenodes-system-collections-generic-ienumerable-of-opc-uafx-opcbrowsenode)<span class="api-meta">since v2.9</span> | Browses the nodes as defined by the `commands` specified to examine their attributes and their references. |
| [BrowseNodes(params OpcBrowseNode\[\])](#browsenodes-opc-uafx-opcbrowsenode-array)<span class="api-meta">since v2.9</span> | Browses the nodes as defined by the `commands` specified to examine their attributes and their references. |

**Exceptions (all overloads)**

| Exception | Condition |
|---|---|
| [OpcException](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcexception/) | The client is not connected to the server. |
| [ObjectDisposedException](https://learn.microsoft.com/dotnet/api/system.objectdisposedexception) | The object has been disposed of. |

## BrowseNodes(IEnumerable&lt;OpcBrowseNode&gt;)

<span class="api-meta">since v2.9</span>

Browses the nodes as defined by the `commands` specified to examine their attributes and their references.

<div class="api-signature" data-lang="csharp">

```csharp
public IEnumerable<OpcNodeInfo> BrowseNodes(IEnumerable<OpcBrowseNode> commands)
```

</div>

<div class="api-signature" data-lang="vbnet">

```vbnet
Public Function BrowseNodes(
    commands As IEnumerable(Of OpcBrowseNode)) As IEnumerable(Of OpcNodeInfo)
```

</div>

**Parameters**

| Name | Type | Description |
|---|---|---|
| `commands` | [IEnumerable](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1)&lt;[OpcBrowseNode](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcbrowsenode/)&gt; | A sequence of [OpcBrowseNode](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcbrowsenode/) commands, each defining the node, the view, the type of references and the degree of nodes to browse. |

**Returns**

[IEnumerable](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1)&lt;[OpcNodeInfo](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/)&gt;

A sequence of [OpcNodeInfo](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/) instances, one for each command in the order of the `commands`. Each instance is of the [OpcNodeInfo](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/) class or of one of its derived classes depending on the category of the node.

**Exceptions**

| Exception | Condition |
|---|---|
| [ArgumentNullException](https://learn.microsoft.com/dotnet/api/system.argumentnullexception) | The `commands` sequence is a null reference (Nothing in Visual Basic). |
| [LicenseException](https://learn.microsoft.com/dotnet/api/system.componentmodel.licenseexception) | The license is expired. |

**Remarks**

The sequence returned is evaluated deferred: the `commands` are verified and processed and the exceptions documented are thrown not before the sequence is enumerated. In case there a node cannot be found or retrieved from the server no exception is thrown; instead an [OpcNodeInfo](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/) is provided whose [Category](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/members#category) is [Unspecified](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnodecategory/#unspecified).

## BrowseNodes(params OpcBrowseNode\[\])

<span class="api-meta">since v2.9</span>

Browses the nodes as defined by the `commands` specified to examine their attributes and their references.

<div class="api-signature" data-lang="csharp">

```csharp
public IEnumerable<OpcNodeInfo> BrowseNodes(params OpcBrowseNode[] commands)
```

</div>

<div class="api-signature" data-lang="vbnet">

```vbnet
Public Function BrowseNodes(
    ParamArray commands As OpcBrowseNode()) As IEnumerable(Of OpcNodeInfo)
```

</div>

**Parameters**

| Name | Type | Description |
|---|---|---|
| `commands` | params [OpcBrowseNode](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcbrowsenode/)[] | An array of [OpcBrowseNode](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcbrowsenode/) commands, each defining the node, the view, the type of references and the degree of nodes to browse. |

**Returns**

[IEnumerable](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1)&lt;[OpcNodeInfo](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/)&gt;

A sequence of [OpcNodeInfo](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/) instances, one for each command in the order of the `commands`. Each instance is of the [OpcNodeInfo](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/) class or of one of its derived classes depending on the category of the node.

**Exceptions**

| Exception | Condition |
|---|---|
| [ArgumentNullException](https://learn.microsoft.com/dotnet/api/system.argumentnullexception) | The `commands` array is a null reference (Nothing in Visual Basic). |

**Remarks**

The sequence returned is evaluated deferred: the `commands` are verified and processed and the exceptions documented are thrown not before the sequence is enumerated. In case there a node cannot be found or retrieved from the server no exception is thrown; instead an [OpcNodeInfo](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/) is provided whose [Category](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.client.opcnodeinfo/members#category) is [Unspecified](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcnodecategory/#unspecified).
