Retrieving Installed Updates

I cannot recall if I read it, or I heard it, but either way a while back I either read, or heard that using the Get-HotFix cmdlet is not the best way to retrieve a list of all installed updates on a system. If it is not the best way, then what is? Should I query the Registry?

Any help would be, of course, greatly appreciated.

Thank you

You can query the registry for this information, specifically the ‘HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages’ is what you would like to query.

Alternatively you can use the Microsoft.Update.Session Com Object to retrieve the information or WMI to query for this. I know the scripting guy did a informative blog post on the WMI approach: Use PowerShell to Easily Find Information About Hotfixes

Thanks Jaap, I actually found it and am using the Microsoft.Update.Session Com Object.

I saw your posting on as well in response to another person mentioning the com object.

Appreciate your response.

No problem Sir Ask Alot! And yes I frequent as well, I am glad to help you out. Let me know if I can help you with anything else.