![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
![]() |
| |
| | #1 (permalink) |
| | win32_product not valid I am in the process of writing a query for win32_product but the component is not installed on some of our boxes. I don't have the luxury of adding this component, is there a another way to gather installed apps on a server via powershell? Thanks in advance, |
My System Specs![]() |
| | #2 (permalink) |
| | Re: win32_product not valid By component I assume you mean the Win32_Product? You can query the HKLM\Software Regkey. Unfornutately, its a little over zealous (Win32_Product only display stuff installed using Windows Installer... this is everything) on the results, but it may be good enough for your purposes. CODE: ================ function Get-InstalledApplications{ Param($server) $hklm = [Microsoft.Win32.RegistryKey]::OpenRemoteBaseKey([Microsoft.Win32.RegistryHive]::LocalMachine,$server) $InstalledApps = $hklm.OpenSubKey("Software") $InstalledApps.GetSubKeyNames() } ================ "Frank" <Frank@discussions.microsoft.com> wrote in message news:C3E77008-3FA6-40A3-AE5C-F6DA998211B2@microsoft.com... >I am in the process of writing a query for win32_product but the component >is > not installed on some of our boxes. I don't have the luxury of adding > this > component, is there a another way to gather installed apps on a server via > powershell? > > Thanks in advance, > > |
My System Specs![]() |
| | #3 (permalink) |
| | Re: win32_product not valid I find that a good substitute is looking at the Uninstall key. It doesn't show you everything though. PS HKLM:\> pushd HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall PS HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall> get-itemproperty * | ft PSChildName, DisplayName PSChildName DisplayName ----------- ----------- Connection Manager Microsoft .NET Framework 2.0 SDK (x64) - ENU Microsoft .NET Framework 2.0 SDK (x64) - ENU Microsoft Visual Studio 2005 Remote Debugger (x64) - ENU Microsoft Visual Studio 2005 Remote Debugger (x64) - ENU {23EA8626-1A8A-453A-ACC4-77CED745849A} Microsoft .NET Framework 2.0 SDK (x64) - ENU {5ADF3AE1-035F-4366-A554-27EF55449BBB} Debugging Tools for Windows 64-bit {6E8E85E8-CE4B-4FF5-91F7-04999C9FAE6A} Microsoft Visual C++ 2005 Redistributable (x64) {751EE164-9F12-4E57-ADB0-02D8F34A10AD} Microsoft SQL Server Native Client {75F299F3-8234-47CD-BB40-2994C1B1105E} Microsoft Visual Studio 2005 64bit Prerequisites (x64) -... {90120000-002A-0000-1000-0000000FF1CE} Microsoft Office Office 64-bit Components 2007 {90120000-002A-0409-1000-0000000FF1CE} Microsoft Office Shared 64-bit MUI (English) 2007 {90120000-0116-0409-1000-0000000FF1CE} Microsoft Office Shared 64-bit Setup Metadata MUI (Engli... {AA0AA91C-2C23-452C-B62F-70054E856AB8} Microsoft SQL Server VSS Writer {AB33D723-6E62-4D9B-8364-87A3161A3335} Microsoft Visual Studio 2005 Remote Debugger (x64) - ENU {B06C23BC-1E66-EF29-71D1-28AAAFE5EABF} ATI Catalyst Install Manager {EB7606A2-2AD9-4F6E-8D01-C2CAB864895C} Windows PowerShell(TM) 1.0 (Microsoft Internal Only) {F11828DF-776B-9876-1AB6-E61A62B97086} ccc-utility64 "Brandon Shell" <tshell.mask@mk.gmail.com> wrote in message news:ur7ybi3kHHA.4960@TK2MSFTNGP02.phx.gbl... > By component I assume you mean the Win32_Product? > > You can query the HKLM\Software Regkey. Unfornutately, its a little over > zealous (Win32_Product only display stuff installed using Windows > Installer... this is everything) on the results, but it may be good enough > for your purposes. > > CODE: > ================ > function Get-InstalledApplications{ > Param($server) > $hklm = > [Microsoft.Win32.RegistryKey]::OpenRemoteBaseKey([Microsoft.Win32.RegistryHive]::LocalMachine,$server) > $InstalledApps = $hklm.OpenSubKey("Software") > $InstalledApps.GetSubKeyNames() > } > ================ > > "Frank" <Frank@discussions.microsoft.com> wrote in message > news:C3E77008-3FA6-40A3-AE5C-F6DA998211B2@microsoft.com... >>I am in the process of writing a query for win32_product but the component >>is >> not installed on some of our boxes. I don't have the luxury of adding >> this >> component, is there a another way to gather installed apps on a server >> via >> powershell? >> >> Thanks in advance, >> >> > |
My System Specs![]() |
| | #4 (permalink) |
| | Re: win32_product not valid "Marcel J. Ortiz [MSFT]" <mosoto@online.microsoft.com> wrote in message news:OCSfOA%23kHHA.1388@TK2MSFTNGP05.phx.gbl... >I find that a good substitute is looking at the Uninstall key. It doesn't >show you everything though. > > PS HKLM:\> pushd HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall > PS HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall> > get-itemproperty * | ft PSChildName, DisplayName I typically use this approach also because gwmi Win32_Product is phenomenally slow on most machines that I have tried it on. -- Keith |
My System Specs![]() |
![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| win32_product in windows 2003 | VB Script | |||
| Win32_Product InstallDate | PowerShell | |||
| win32_product uninstall method | PowerShell | |||
| Get-WmiObject Win32_Product | PowerShell | |||
| WMI Object Win32_Product and Pipeline woes | PowerShell | |||