Power Script to Uninstall Application

This is the simple command to execute this task

$app = Get-WmiObject -Class Win32_Product | Where-Object {
$_.Name -match “Software Name”
}

$app.Uninstall()

Copy the above syntax to a text editor, e.g, notepad

The application to uninstall here is EmEditor and this can be run against a whole lot of servers via the run command on AWS and does not require a restart.

 

Open the PowerShell CLI
run the file from the location it is saved and run it. The below is the result that will be dispalyed

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s