Get-RemoteProgram Get list of installed programs on remote or local computer

This script generates a list by querying the registry and returning the installed programs of a local or remote computer. It allows for retrieval of additional properties such as the uninstall string of an application as well.

 
 
 
 
 
4.4 Star
(65)
111,441 times
Add to favorites
Operating System
8/5/2019
E-mail Twitter del.icio.us Digg Facebook
Sign in to ask a question


  • No output after running script
    3 Posts | Last post August 03, 2019
    • I've run the script on a Windows 7 and Windows 10 computer and not getting any output.  I have a powershell window open with run as admin.
      This is the command line I enter on the prompt
      .\Get-RemotePrograms.ps1
      
      Any idea why I'm not getting any output?
    • Found my issue.  This is function and has to be called from a powershell script.  Load the module into your powershell script then call it.
    • Glad to hear you resolved the issue, let me know if there's anything else I can help you with!
  • Want modification?
    3 Posts | Last post August 02, 2019
    • Hi, Jaap.
      
      I made some changes to this script because it was missing installed programs in HKCU. Because that involved using a different base key, the changes were a bit more involved than just adding another string to the $RegistryLocation array.
      
      If you care, I can send you my version. Let me know.
      
      Thanks,
      Chip
    • Hello chip. I just found out the same. Would it be possible to get a copy of your modified script?
    • There is an updated version of the script available, let me know how that works for you!
  • Search HKCU
    2 Posts | Last post August 02, 2019
    • Awesome script and have put it to good use but just found that it isn't finding a known installed program that resides in the HKCU registry section. Is the script supposed to search both HKCU and HKLM?
    • Hello jcfrazier6,
      
      I have updated my script and have added some additional features as well, let me know if this works better for you!
      
      Here is the changelog for the 1.5 version:
      
      Version 1.5 - Feature update
      
      Added -DisplayRegPath switch parameter, displays which registry key was queried for the program
      Added -MicrosoftStore switch parameter, queries currentuser package list to also list installed Microsoft Store packages
      Added Write-Verbose statement to follow what the script is querying
      Now also queries HKCU, before only queried HKLM which did not provide a full list of installed programs
  • Calling the following uninstall string
    1 Posts | Last post March 28, 2019
    • Any idea how I can call the following uninstall string? 
      
      MsiExec.exe /I{B454B5C8-5C87-4F24-B9F5-2A9A199F08F5}
      
  • Task Scheduler
    3 Posts | Last post January 31, 2019
    • Great Stuff!  I am new to powershell but I was wondering if you may suggest how i can run this in some sort of task scheduler or batch script?
      
      I don't have any issue when i run it in powershell but i would like to create it as a batch so that i can run it as standalone or in the task scheduler.
      I am using the command below 
      C:\Get-RemoteProgram.ps1 
      Get-Content -Path C:\serverlist.txt | Get-RemoteProgram 
    • try running as 
      
      PowerShell.exe -NoProfile -ExecutionPolicy Bypass -command "& {. .\Get-RemoteProgram.ps1;Get-RemoteProgram -ComputerName (Get-Content -Path C:\serverlist.txt) -Property DisplayVersion,VersionMajor}";
      
    • +1, thnks!
  • Possibility to have hostname and use the -or clause
    1 Posts | Last post November 13, 2018
    • Is it possible to have a field that tells me the name of the pc (hostname) if in the node I introduce the ip addresses and it is possible -IncludeProgram to use the -or clause?
      I thank you in advance I tried to do it with this code but it gives me an error
      $ nodes = 19..200 | % {"172.17.160. $ _"}
      #$Programs = $ '* Office *', '* Autocad *'
      Get-RemoteProgram -ComputerName $ nodes -IncludeProgram ('*Office*' -or '*Autocad*') | Sort-Object ProgramName | Export-Csv -Path c:\TEMP\PcConProgrammi.txt -Force
      
  • Program Name length
    1 Posts | Last post July 24, 2018
    • Does anyone know how i can increase the Program Name length instead of the ...
      e.g. Symantec Netback... should be Symantec Netbackup
      
      ComputerName        ProgramName         DisplayVersion      VersionMajor       
      ------------        -----------         --------------      ------------       
      Compute1            Microsoft System... 12.2.5579.0         12                 
      Compute1            Symantec NetBack... 7.7.3               7                  
      Compute1            SQL Server 2014 ... 12.2.5000.0         12                 
      Compute1            SQL Server 2014 ... 12.2.5000.0         12                 
      Compute1            SQL Server 2014 ... 12.2.5000.0         12   
  • OpenRemoteBaseKey issue
    3 Posts | Last post July 18, 2018
    • Hi Jaap,
      
      I run this script to remote client , always show Exception calling "OpenRemoteBaseKey" with "2" argument(s)
      
      How to solve it for remote clients?
      
      Thanks!
    • Same problem... :-(
    • I found that the remote registry service was not started on the PC that I was working with.
      To see if the service was running I used:
      Get-Service -ComputerName RemotePC1 -Name RemoteRegistry
      
      Start service if necessary:  
      Get-Service -ComputerName RemotePC1 -Name RemoteRegistry | Start-Service
      
      Reference: https://community.spiceworks.com/topic/1432811-problem-with-a-powershell-script-on-several-machines
  • Excluding known Apps
    7 Posts | Last post April 10, 2018
    • Hello, great script!
      
      I was wondering if I could remove results that are on every PC using an array ( txt file)
      
      Example, every Pc in my domain has Adobe Air, Flash, Office etc set for compliance
      
      We’re doing a refresh project soon and I was hoping to make this a bit more efficient.
      
      I’d like to use the text file instead of within the application so I only have to update the external txt file
    • Hello WindowsUser127,
      
      I have introduced the ExcludeProgram/IncludePRogram parameter for this purpose. So depending on if you want to include / exclude the programs you mentioned you could run either:
      
      Get-RemoteProgram -ExcludeProgram 'Adobe Air|Flash|Office' -ProgramRegExMatch
      
      Or to include and only display the programs you specify:
      Get-RemoteProgram -IncludeProgram 'Adobe Air|Flash|Office' -ProgramRegExMatch
      
      
      Let me know how that works for you!
      
      
      Regards,
      
      Jaap Brasser
    • I don't see a way to put items in a txt file?  Currently my text file looks like this
      
      Adobe Air*
      Adobe Flash*
      AMD HD Video Driver and Control Panel*
      IDT High Definition Audio Driver*
      
      etc....
    • and sorry...  this is phenomenal work.
      I'm just trying to keep the excluded items in a separate txt so I'm not editing the script.
    • Ignore me.  I figured out the text file
      
      I did run into an issue with Microsoft Visual C++ 2005 Redistributable
      
      C++" - Nested quantifier +.
      At line:1 char:1
      + Get-RemoteProgram -ExcludeProgram $exclude -ProgramRegExMatch  | Sort ...
      + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : NotSpecified: (:) [Write-Error], WriteErrorException
          + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Get-RemoteProgram
    • Hello WindowsUser127,
      
      I don't know what your $Exclude variable contains exactly, but since we are doing regular expression matching you should be careful with special characters such as + . ? *.
      
      One option is to escape everything in your text file, so if you have a multiline text file containing the following:
      
      Adobe Air
      Adobe Flash
      AMD HD Video Driver and Control Panel
      IDT High Definition Audio Driver
      Microsoft Visual C++ 2005 Redistributable
      
      You could exclude these by doing the following:
      Get-RemoteProgram -ProgramRegExMatch -ExcludeProgram (Get-Content YourFile.txt | ForEach-Object {[regex]::Escape($_)}) -join '|')
    • Wonderful, let me work on this and provide feedback when I can.
  • icm method
    4 Posts | Last post April 08, 2018
    • Hello Jaap,
      i've modified your script to use invoke-command & get-itemproperty method instead of remote registry service. In my experience it provides results much faster and works around using smb comm port 445 which is frequently blocked on servers.
      Let me know what you think about it: https://gallery.technet.microsoft.com/scriptcenter/Get-RemoteApplication-05cfd58a
      
      Thomas
    • Hi no_escape,
      
      I like your idea, nice modifications and good to leverage PowerShell remoting. It is definitely the way forward for the future.
      
      But if your goal is remote execution then you could also invoke Get-RemoteProgram using Invoke-Command and it would be even faster. Because the .Net Classes used in this function are faster than the PowerShell cmdlets that are used in Get-RemoteApplication. For comparison try the following Command:
      
      [pscustomobject]@{RemoteProgram = (measure-command {Get-RemoteProgram}).TotalMilliseconds;RemoteApplication=(measure-command {get-remoteapplication}).TotalMilliseconds}
      
      The advantage of remote registry is that you are not relying on PowerShell Remoting which helps in mixed environments, for which this function was developed.
      
    • Thanks for your comment, I should have tested the performance between the cmdlets and the .net class first :) Yes my goal was remote execution. Guess its better to just invoke the original version with icm, the performace is much better in favor of the .net class like you've said.
      
      Still, maybe you could incorporate the icm solution in case people want to execute this remotely? Remote registry service is painfully slow from my experience. Just an idea to share with others, I am more than happy to tweak the script for my own purposes.
      
      Regards,
      
      Thomas
    • Hello Thomas,
      
      I agree, that would be a valuable feature, I intended to implement this in a future release. You can track the issue here: https://github.com/jaapbrasser/SharedScripts/issues/22
      
      
      Regards,
      
      Jaap Brasser
11 - 20 of 81 Items