Finding install/uninstall commands for .exe apps for Win32 packaging in Intune

DISCLAIMER: THIS WAS ORIGINALLY A LINKEDIN POST HENCE THE STRUCTURE OF THE POST

Using Win32 packaging is a smooth and efficient way to package and push out .exe applications to Windows clients via Intune.

However, Intune requires two important strings:
InstallCommand and UninstallCommand.

These commands can be found in different ways — sometimes on the vendor’s website, sometimes via a simple Google search, or even by asking ChatGPT. BUT sometimes it’s much harder than that…

An install command is, in most cases, just the name of the .exe file followed by /s, /S, /q, /quiet, or /sq. You can often try a few of these and figure it out by trial and error.

The uninstall command can be a bit trickier, especially with specific apps — so here are two simple tips I often use to help find it! 💡

Try the .exe file with `/?” in Command Prompt

This often opens a window that displays available parameters (see example in image above).

Install the app locally, then check the Registry Editor:

  • HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall
  • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall

Look for the name of your application (sometimes the folder names are long strings of numbers and letters — so put on your detective hat and check the DisplayName field to find the right one) 🕵️‍♂️

Once you’ve found your app, look for the “UninstallString” (highlighted in the image). Open it and copy that string into Intune.

Like many things, it won’t always work perfectly — but in many cases, it does, so it’s definitely worth trying! 🌟

Leave a Reply

Your email address will not be published. Required fields are marked *