# OpcMethodCommands.ExecuteDelegate Delegate

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

<dl class="api-definition">
<dt>Namespace</dt>
<dd><a href="../namespaces/opc.uafx">Opc.UaFx</a></dd>
<dt>Assembly</dt>
<dd>Opc.UaFx.Advanced.dll</dd>
<dt>Package</dt>
<dd>Opc.UaFx.Advanced v2.59.0</dd>
</dl>

Represents the method that will be executed whenever the command defined is called.

## Syntax

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

```csharp
public delegate OpcResult OpcMethodCommands.ExecuteDelegate(
    OpcMethodContext context,
    IList<object> inputArguments,
    IList<object> outputArguments)
```

</div>

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

```vbnet
Public Delegate Function OpcMethodCommands.ExecuteDelegate(
    context As OpcMethodContext,
    inputArguments As IList(Of Object),
    outputArguments As IList(Of Object)) As OpcResult
```

</div>

## Parameters

| Name | Type | Description |
|---|---|---|
| `context` | [OpcMethodContext](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcmethodcontext/) | The [OpcMethodContext](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcmethodcontext/) which provides the contextual information required to execute the command. |
| `inputArguments` | [IList](https://learn.microsoft.com/dotnet/api/system.collections.generic.ilist-1)&lt;[Object](https://learn.microsoft.com/dotnet/api/system.object)&gt; | The generic list of [object](https://learn.microsoft.com/dotnet/api/system.object) values to use / respect during the execution of the method. |
| `outputArguments` | [IList](https://learn.microsoft.com/dotnet/api/system.collections.generic.ilist-1)&lt;[Object](https://learn.microsoft.com/dotnet/api/system.object)&gt; | The generic list of [object](https://learn.microsoft.com/dotnet/api/system.object) values to use for out, ref (in Visual Basic ByRef) and returned values. |

## Returns

[OpcResult](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcresult/)

The [OpcResult](https://www.traeger.de/en/docs/development/opcua/api/v2.59/opc.uafx.opcresult/) which contains information about the outcome of the invocation of the command.

## Applies to

| Package | Versions |
|---|---|
| Opc.UaFx.Advanced | v2.24–v2.59 |
