Update Application via Win32App in Microsoft Intune

This blog is about updating an application which you can not update through automation like Chocolately and/or PatchMyPC. I am going to update an application via Win32App in Microsoft Intune. I am deploying this using a script which first uninstalls the old version and then installs the new one. The application that I am going to update is SmartLockr.

Prerequisites

We need to create a couple of files

The first file is the installer for the latest version of Smartlockr of your line of business application.

The second file is a Powershell Script. This is the syntax:

The script needs some explanation. The first line collects all the applications installed on your machine, for example:

This information is stored in an array called $SmartLockrGUID.

In the second part of the script we are going to search the installed application and check if the GUID of the old version of Smartlockr is installed. After that we going to uninstall this application:

You can get this GUID (“{D6F8DEFE-10D0-4C29-A31B-589A1A49BAC9}”) by running the following command:

This will give you the GUID for Smartlockr or your business application:

The last part of the script is going to install the new version of SmartLockr or your business application

You can get this GUID the same way you did with the old version and then your output will be this:

Your script is now complete, it is now time to setup the install.cmd CMD file. This file contains this code:

This .cmd file copies the files and runs the script.

Packaging

We are now going to package this folder to create a .intunewin file. You are going to need the IntuneWinAppTool. You can download this here link.

This is a command line utility:

You will end up with an .intunewin file:

Deployment

The Win32App now need to be deployed.

Log on to the Intune Portal at https://devicemanagement.microsoft.com/

Go to Apps:

After that go to Windows and add an App:

Add a Win32App:

Select app package file and browse to the SmartLockr for Outlook 4.3.030420.1-all-users.intunewin file.

Specify the package information:

Fill in the program information. The uninstall command will be filled for you due to the MSI in the .intunewin file:

Specify requirements:

Configure the detection rules:

At depencies click next.

Assign the application:

And the update is deployed!

References

IntuneWinAppUtil

More Win32App deployments:
Internet Shortcut via Win32App
Chrome Extension via Win32App

Related Posts

Leave a Reply