Advertisement
Guest User

UWPInfo

a guest
Mar 1st, 2017
181
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function Show-Menu
  2.  {
  3.       param (
  4.             [string]$Title = 'UWP Application Information'
  5.       )
  6.       cls
  7.       Write-Host "================ $Title ================"
  8.       Write-Host ""
  9.       Write-Host "1: Press '1' for a simplified list of all installed UWP app packages for the current user on this PC."
  10.       Write-Host "2: Press '2' for a detailed list of all installed UWP app packages for the current user on this PC"
  11.       Write-Host "3: Press '3' for a simplified list of all installed UMP app packages for all users on this PC."
  12.       Write-Host "4: Press '4' for a detailed list of all installed UMP app packages for all users on this PC."
  13.       Write-Host "Q: Press 'Q' to quit."
  14.       Write-Host ""
  15.  }
  16.  
  17. do
  18. {
  19.       Show-Menu
  20.       $input = Read-Host "Please make a selection"
  21.       switch ($input)
  22.       {
  23.             '1' {
  24.                  cls  
  25.                  Get-AppxPackage -user $env:UserName | Select Name, PackageFullName
  26.             } '2' {
  27.                  cls
  28.                  Get-AppxPackage -user $env:UserName
  29.             } '3' {
  30.                  cls
  31.                  Get-AppxPackage -allusers | Select Name, PackageFullName
  32.             } '4' {
  33.                  cls
  34.                  Get-AppxPackage -allusers
  35.             } 'q' {
  36.                  return
  37.             }
  38.       }
  39.       pause
  40.  }
  41.  until ($input -eq 'q')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement