PowerShell

How to uninstall an application using PowerShell Script

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

Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x