How to uninstall software using batch file

Solution 1:

I think WMIC commands can be run from a single line which should make it easier to add to a batch file. And by adding /nointeractive then it should disable prompting as well. Try something like this:

wmic product where name="software" call uninstall /nointeractive

Solution 2:

Although that may be possible for certain specific installations it's not possible to do so for all installations. As Zypher has already indicated, it will depend a great deal on the installation system used. It will also depend on whether that system allows for a "quiet" uninstall.

I really can't image a "perfect method using WMI" but congratulations if you've found one. On the other hand, you've also discovered one of the things that will get in the way of achieving your goal.