i have tried with different powershell scripts but in the output few installed applications are missing.
My Request: I have 1000+ servers with different Windows OS versions. need script to fetch all the application details installed onto the servers.



Hello there,
Please try to use the following code. It performs additional registry check. I’m using it on 2008R2, 2012R2 and have no missing entries.
On the last line, change the $HOSTNAME to a list of computers or single remote host. (The script is using PSRemoting, so be sure that the remote hosts have PSRemoting enabled).
$InstSoftBlock = {
$AllinstallKeys = @()
$UninstallKeys = Get-ItemProperty “HKLM:\Software\Microsoft\Windows\CurrentVersion\Uninstall\*”
Foreach ($key in $UninstallKeys)
{
$InstSoftObject1 = New-Object PSObject
Add-Member -inputObject $InstSoftObject1 -memberType NoteProperty -name “DISPLAYNAME” -value $key.DisplayName
Add-Member -inputObject $InstSoftObject1 -memberType NoteProperty -name “DISPLAYVERSION” -value $key.DisplayVersion
Add-Member -inputObject $InstSoftObject1 -memberType NoteProperty -name “KEY” -value $key.PSChildName
$AllinstallKeys += $InstSoftObject1
}
#Additional registry check
If ($UninstallKeys2 = Get-ItemProperty “HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\*” -ErrorAction SilentlyContinue)
{
Foreach ($key2 in $UninstallKeys2)
{
$InstSoftObject2 = New-Object PSObject
Add-Member -inputObject $InstSoftObject2 -memberType NoteProperty -name “DISPLAYNAME” -value $key2.DisplayName
Add-Member -inputObject $InstSoftObject2 -memberType NoteProperty -name “DISPLAYVERSION” -value $key2.DisplayVersion
Add-Member -inputObject $InstSoftObject2 -memberType NoteProperty -name “KEY” -value $key2.PSChildName
$AllinstallKeys += $InstSoftObject2
}
}
$AllinstallKeys
}
#Establish remote connection
$InstSoftObj = Invoke-Command -ComputerName $HOSTNAME -scriptblock $InstSoftBlock