0% found this document useful (0 votes)
8 views1 page

MKT Block Script2

Uploaded by

silumanlampu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as ODT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views1 page

MKT Block Script2

Uploaded by

silumanlampu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as ODT, PDF, TXT or read online on Scribd

Method 2: Using PowerShell (Preferred for Modern Systems)

1. Enable PowerShell Remoting on the remote machine (if not already enabled): Run the
following on the remote machine:
powershell
Copy code
Enable-PSRemoting -Force

2. Open PowerShell on your local machine with administrator privileges.


3. Connect to the remote machine and list installed applications:
powershell
Copy code
Invoke-Command -ComputerName <RemoteComputerName> -Credential (Get-
Credential) -ScriptBlock {
Get-WmiObject -Class Win32_Product | Select-Object Name
}

Replace <RemoteComputerName> with the name or IP address of the remote machine.

4. Uninstall the application:


powershell
Copy code
Invoke-Command -ComputerName <RemoteComputerName> -Credential (Get-
Credential) -ScriptBlock {
$app = Get-WmiObject -Class Win32_Product | Where-Object { $_.Name -eq
"<ApplicationName>" }
$app.Uninstall()
}

Replace <ApplicationName> with the exact name of the application.

You might also like