Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- foreach ($app in (Get-WmiObject -Query "Select * from Win32_Product where name like 'Microsoft Visual Studio Professional %'")) {
- Write-Host "Deleting $app.Name"
- &"msiexec.exe" /norestart /q/x $app.IdentifyingNumber REMOVE=ALL
- #$app.Uninstall()
- }
- foreach ($app in (Get-WmiObject -Query "Select * from Win32_Product where name like 'Microsoft SQL Server %'")) {
- Write-Host "Deleting $app.Name"
- &"msiexec.exe" /norestart /q/x $app.IdentifyingNumber REMOVE=ALL
- #$app.Uninstall()
- }
- foreach ($app in (Get-WmiObject -Query "Select * from Win32_Product where name like 'Microsoft Azure %'")) {
- Write-Host "Deleting $app.Name"
- &"msiexec.exe" /norestart /q/x $app.IdentifyingNumber REMOVE=ALL
- #$app.Uninstall()
- }
- foreach ($app in (Get-WmiObject -Query "Select * from Win32_Product where name like 'Microsoft .NET Framework %'")) {
- Write-Host "Deleting $app.Name"
- &"msiexec.exe" /norestart /q/x $app.IdentifyingNumber REMOVE=ALL
- #$app.Uninstall()
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement