Uninstall with system account

Iron Contributor

I am trying to uninstall a software and it is specified that the 

Install behavior to be  System
 
I am not able to uninstall the software through PowerShell. When I run the PowerShell script locally it prompts me enter my service account which is how we install software or uninstall software. I am not sure how we could overrule this and install or uninstall software's? I thought SYSTEM account should take care of this.
 
 

# Set execution policy to bypass
Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope Process -Force

# Get the uninstall string from the registry
$uninstallString = (Get-ItemProperty "HKLM:\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall\{1B4AF183-7693-42EC-B7EE-B6B1FB0140F0}_is1").UninstallString

# Start the uninstallation process with administrative privileges
Start-Process -FilePath $uninstallString -ArgumentList "/SILENT" -Wait -Verb RunAs

 
 
0 Replies