Scripting Question

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'

Comments

All Answers

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.

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

Share

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