Under path "Control Panel\Programs\Programs and Features", here is a list to show the currently installed programs, now I want to get the list with powershell, I tried below two commands, but they returned a different result counts, neither much or less than the expect one. anyone knows how to do with it?
Note: The counts is 144 (the expected number) when checked with appwiz.cpl
PS C:\Users\testuser> $a = Get-WmiObject -Class win32_product | Select-Object Name
PS C:\Users\testuser> $a.count
275
PS C:\Users\testuser> $b = Get-ItemProperty 'hklm:\software\microsoft\windows\currentversion\uninstall\*' | Where-Object {$_.DisplayName}
PS C:\Users\testuser> $b.Count
113