# GetVariableByNameAsync Method

## Overloads

| [GetVariableByNameAsync(String)](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.App.GetVariableByNameAsync.htm#Qlik_Engine_App_GetVariableByNameAsync_System_String_) |  | Gets the handle of a variable. |
| --- | --- | --- |
| [GetVariableByNameAsync(AsyncHandle, String)](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.App.GetVariableByNameAsync.htm#Qlik_Engine_App_GetVariableByNameAsync_Qlik_Engine_AsyncHandle_System_String_) |  | Gets the handle of a variable. |
| [GetVariableByNameAsync<T>(AsyncHandle, Func<Response, T>, String)](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.App.GetVariableByNameAsync.htm#Qlik_Engine_App_GetVariableByNameAsync__1_Qlik_Engine_AsyncHandle_System_Func_Qlik_Engine_Communication_IO_Response___0__System_String_) |  | Gets the handle of a variable. |

[](https://help.qlik.com/en-US/sense-developer/Subsystems/NetSDKAPIref/Content/Qlik.Engine.App.GetVariableByNameAsync.htm) [](https://help.qlik.com/en-US/sense-developer/Subsystems/NetSDKAPIref/Content/Qlik.Engine.App.GetVariableByNameAsync.htm)

## GetVariableByNameAsync(String)

Gets the handle of a variable.

### Declaration

```

          public Task<GenericVariable> GetVariableByNameAsync([QixName("qName")] string name)
    
  
```

### Parameters

| Type | Name | Description |
| --- | --- | --- |
| System.String | name | Name of the variable. |

### Returns

| Type | Description |
| --- | --- |
| System.Threading.Tasks.Task&lt;[GenericVariable](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.GenericVariable.htm)&gt; |  |

### Implements

[IApp.GetVariableByNameAsync(String)](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.IApp.GetVariableByNameAsync.htm#Qlik_Engine_IApp_GetVariableByNameAsync_System_String_)

[](https://help.qlik.com/en-US/sense-developer/Subsystems/NetSDKAPIref/Content/Qlik.Engine.App.GetVariableByNameAsync.htm) [](https://help.qlik.com/en-US/sense-developer/Subsystems/NetSDKAPIref/Content/Qlik.Engine.App.GetVariableByNameAsync.htm)

## GetVariableByNameAsync(AsyncHandle, String)

Gets the handle of a variable.

### Declaration

```

          public Task<GenericVariable> GetVariableByNameAsync(AsyncHandle asyncHandle, [QixName("qName")] string name)
    
  
```

### Parameters

| Type | Name | Description |
| --- | --- | --- |
| [AsyncHandle](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.AsyncHandle.htm) | asyncHandle | Handle to asynchronous method request |
| System.String | name | Name of the variable. |

### Returns

| Type | Description |
| --- | --- |
| System.Threading.Tasks.Task&lt;[GenericVariable](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.GenericVariable.htm)&gt; |  |

### Implements

[IApp.GetVariableByNameAsync(AsyncHandle, String)](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.IApp.GetVariableByNameAsync.htm#Qlik_Engine_IApp_GetVariableByNameAsync_Qlik_Engine_AsyncHandle_System_String_)

[](https://help.qlik.com/en-US/sense-developer/Subsystems/NetSDKAPIref/Content/Qlik.Engine.App.GetVariableByNameAsync.htm) [](https://help.qlik.com/en-US/sense-developer/Subsystems/NetSDKAPIref/Content/Qlik.Engine.App.GetVariableByNameAsync.htm)

## GetVariableByNameAsync&lt;T&gt;(AsyncHandle, Func&lt;Response, T&gt;, String)

Gets the handle of a variable.

### Declaration

```
public Task<T> GetVariableByNameAsync<T>(AsyncHandle asyncHandle, Func<Response, T> onResult, [QixName("qName")] string name)
```

### Parameters

| Type | Name | Description |
| --- | --- | --- |
| [AsyncHandle](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.AsyncHandle.htm) | asyncHandle | Handle to asynchronous method request |
| System.Func&lt;[Response](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.Communication.IO.Response.htm), T&gt; | onResult | Continuation function |
| System.String | name | Name of the variable. |

### Returns

| Type | Description |
| --- | --- |
| System.Threading.Tasks.Task&lt;T&gt; |  |

### Type Parameters

| Name | Description |
| --- | --- |
| T |  |

### Implements

[IApp.GetVariableByNameAsync<T>(AsyncHandle, Func<Response, T>, String)](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.IApp.GetVariableByNameAsync.htm#Qlik_Engine_IApp_GetVariableByNameAsync__1_Qlik_Engine_AsyncHandle_System_Func_Qlik_Engine_Communication_IO_Response___0__System_String_)