MIcrosoft Teams - Uninstall

Has anyone had any luck uninstalling Microsoft Teams with BigFix? I’ve successfully pushed the agent out, however I’ve hit a few systems on a cross domain that I need to uninstall these from and i’m finding this increasingly more difficult with the way the application install itself.

Notable install qualities:

  • The application is not a “Registered Application.” It installs under the current user profile, with an uninstall string under HKCU instead of HKLM. It is not an MSIExec string and I am unable to find an MSIExec string in either the registry or by running a powershell command for this. The string instead looks like this:

““C:\Users\USERNAME\AppData\Local\Microsoft\Teams\Update.exe” --uninstall”"

I have tried anything as basic as having BigFix open a command prompt to steps that are absolutely far more complex than this should be.

Anyone have any ideas or experience uninstalling this application?

I’ll add my most recent attempt below, while the simplest thing I’ve tried, still does not complete (even though it will successfully uninstall the application if the command is ran locally on the machine. The command will show “Failed” in bigfix, but when drilling down to the steps, all steps show completed.)

//Run Uninstall

waithidden cmd.exe /c cd c: & %localappdata%\Microsoft\Teams\Update.exe --uninstall

In short, no, there is no easy way (due to the nature of the installer).

The MSI installer, which is what you want to use when deploying Teams in an Enterprise, is actually an installer itself. It allows Teams to install for the Profile of anyone logging in. If you instead, deployed the EXE, well that is just the Profile installer and will only show for a single user (you do NOT want to deploy the EXE via BigFix).

Side note: You want to periodically update the MSI for your BF task, so that a current version is being deployed to new endpoints. No need to upgrade existing versions as Teams is self-updating.

If a user should uninstall Teams, it won’t install again and it won’t show uninstalled (relevant) for your BF task (as technically, it is still installed). In this case, you have some options, which are shown here, near the end under “Clean Up”.

In this case, we find it easier to just have the user download the EXE and install again.

2 Likes

Try to run it as current user (using the Override Action Script) - this should allow your %localappdata% variable to resolve as the user that is logged in vs the BigFix Agent’s user context.

Or you might play around with pathnames of files "Update.exe" of folders "AppData\Local\Microsoft\Teams" of folders of folders "C:\Users" in order to generate your path to Update.exe so you can --uninstall

1 Like