# AppWithIdOrDefault Method

## Overloads

| [AppWithIdOrDefault(ILocation, String)](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.LocationExtensions.AppWithIdOrDefault.htm#Qlik_Engine_LocationExtensions_AppWithIdOrDefault_Qlik_Engine_ILocation_System_String_) |  | Connect to a Qlik Sense app with the app id.<br>This method opens a temporary websocket connection. |
| --- | --- | --- |

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

## AppWithIdOrDefault(ILocation, String)

Connect to a Qlik Sense app with the app id. This method opens a temporary websocket connection.

### Declaration

```

          public static IAppIdentifier AppWithIdOrDefault(this ILocation location, string appId)
    
  
```

### Parameters

| Type | Name | Description |
| --- | --- | --- |
| [ILocation](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.ILocation.htm) | location | Location object of the Qlik Sense instance |
| System.String | appId | App identification |

### Returns

| Type | Description |
| --- | --- |
| [IAppIdentifier](https://help.qlik.com/en-US/sense-developer/November2025/Subsystems/NetSDKAPIref/Content/Qlik.Engine.IAppIdentifier.htm) | IAppIdentifier or default if no such app is found. |