

The registry key Uninstall contains all installed applications. There is a faster way to search for an installed application. $app = Get-WmiObject -Class Win32_Product -Filter “Name like ‘%\\iCloud\\%'” $app.Uninstall() | out-string Add an uninstall command to uninstall iCloud: A quick check of the events in my Application Event Log shows over 300 events from MsiInstaller with a message similar to this one: Windows Installer reconfigured the product. On my workstation, this query took over two minutes to complete.


$app = Get-WmiObject -Class Win32_Product -Filter “Name like ‘%\\iCloud\\%'” Even the simplest query can take minutes to run. It seems that WMI attempts to reconfigure every installed product. If you have ever scanned the list of currently installed programs using the WMI Win32_Product class, you’ve noticed that the scan runs slow! This always frustrates me. This script begins by connecting to the WMI service on the local computer (although it can be easily modified to remove printers from a remote computer instead).
