/build/static/layout/Breadcrumb_cap_w.png

Needing a WMI Query for searching an Installed Application on a workstation. Please help.

Has anyone used ManagePC (http://managepc.net/)? I ran into it the other day and it seems pretty neat for being free. There is even a WMI Query Builder. I wanted to check if anyone has a query that I can modify where it will let me find a particular application is installed on a machine.

Per example running a query that will provide me a list of computer that has 'C:\Program Files (x86)\Google\Chrome\Application\Chrome.exe'

Thanks,
Luis

0 Comments   [ + ] Show comments

Answers (3)

Posted by: anonymous_9363 9 years ago
Red Belt
1
If you want to query just for the EXE, then a simple file search script will do. I'd avoid hard-coded paths like 'C:\Program Files(x86)...' Instead, use the environment variable which points at the 32-bit and 64-bit locations for those targets.

If you want to search for specific software, use either the WindowsInstaller.Installer object's ProductState property or, in WMI, use the Win32_Product class's InstallState property. You can find script samples using both of these routes everywhere. All you need do is extract the query part.

Comments:
  • Win32_Product is slow and buggy, better use registry uninstall list. - dedenker 9 years ago
Posted by: anonymous_9363 9 years ago
Red Belt
1
Such bugs as there are are pretty obscure. I can't imagine that the OP would encounter any issues in a simple 'is this product installed' query. 
Posted by: Nico_K 9 years ago
Red Belt
1
you can find the needed info with wmic product where "name like 'java%%'" list (if you search for all installed java versions, for special versions you can modify this) If you replace the list paramater with call uninstall, you are did off this software
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ