Created
April 15, 2016 22:38
-
-
Save jacksoneyton/0c49bae0659020a77a18556848b9b3e8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$qtVer = Get-ChildItem -Path HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall, HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall | | |
Get-ItemProperty | | |
Where-Object {$_.DisplayName -match "quicktime" } | | |
Select-Object -Property DisplayName, UninstallString | |
ForEach ($ver in $qtVer) { | |
If ($ver.UninstallString) { | |
$uninst = $ver.UninstallString | |
$uninst = $uninst -replace "/I", "/x " | |
Start-Process cmd -ArgumentList "/c $uninst /quiet /norestart" -NoNewWindow | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment