Avatar of Pkafkas
 asked on

How to trigger a silent software uninstallation from the command line

Trying to un-install a program from a package and the vendor has not really setup any command - line parameters for this.

We did find out that the un-instlalatin does work from Windows 10 - Programs - Uninstall program.

When one executes the uninstlal manually, a UAC prompt comes up and it states that it will execute:  
File Uninstall command line "C:\Program Files (x86)\FOLDER_HERE\Uninstall.exe" "C:\Program Files (x86)\FOLDER_HERE\Uninstall\install.log"

How can we try to execute this from a command prompt?  I have already turned off Universal Access Control (UAC) for testing purposes.

I guess the question is how to:

1).  Trigger the uninstall.exe file located in: C:\Program Files (x86)\FOLDER_HERE\ - folder

2).  Use the \install.log file located in another folder "C:\Program Files (x86)\FOLDER_HERE\Uninstall\install.log"
Windows 10InstallationWindows OS

Avatar of undefined
Last Comment

8/22/2022 - Mon
Vadim Rapp

You can (1) create startup, shutdown , logon, or logoff script for the group policy, with this command inside; or (2) you can use psexec and run this command remotely on one or more computers

You can (1) create startup, shutdown , logon, or logoff script for the group policy, with this command inside;

No, since that command is not silent.

@pkafkas: did you try and add the usual suspects: 

/s /silent /q /quiet /verysilent

behind uninstall.exe? Often, these work. Use one of them, not any of them in each test, for example

"C:\Program Files (x86)\FOLDER_HERE\Uninstall.exe" /quiet


We do not use Active Directory and Group Policy here.  We use MicroFocus

I think there might be a batch file that can input a log file name but that .log file must be in the same folder.  Plus this software wil not be instlaled on every pc.
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck

This seems to work, "c:\program files (x86)\FOLDER_Here\Uninstall.exe" "c:\program files (x86)\FOLDER_HERE\Uninstall\install.log" -s -var:reboot=0

-s means silent and 1= to reboot 0=not to reboot.

it appears that if you are in an elevated command prompt and put a file within quotes the DOS program will trigger that specifci quoted file.  Then the same for anything else next.  It appears that those 2 files are what was called to trigger the un-install in ADD/Remove Programs.

the other varioable -s  stands for you guessed it ''silent" un-install.  Then the -var: must create or call a windows command like 'reboot' = 0 to not reboot.

Can anyone else provide an explanation how the above command worked?

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question

If I attempted to manually remove the program from my computer, I say the UAC come up and it stated:

GUID …., just like Arnold stated.  So, if I understand correctly, another option is to:

1).  Open command prompt as administrator.
2).  Type: msiexec.exe /X {guid of install package that I see from the UAC - Details} /q /silent /quiet

If that is correct, that is pretty cool as well.