Automating Test Cases Using C# WinAppDriverFetching the Application ID for a Desktop App

Fetching the Application ID for a Desktop App

This article provides you with steps to fetch an application ID for a given application. It depends on the operating system that you are using. In this case, the calculator's application ID is fetched using PowerShell for Windows 10 or 11 machines.

Applicable to Desktop App

Fetching the Application ID

Perform the following:

  1. Press Win + R and enter PowerShell
  2. In the PowerShell window, type the following command and press Enter:
Get-AppxPackage *calculator* | Select-Object Name, PackageFamilyName

This will display the PackageFamilyName, which can be considered the Application ID for the Calculator app (for example, something like Microsoft.WindowsCalculator_8wekyb3d8bbwe). The following screenshot displays the preceding details:

PowerShell window showing Get-AppxPackage calculator command with PackageFamilyName result