Andrei Smolin

Introducing automatic updates for Office extensions

Version 8.3 of Add-in Express for Office and .net added support for automatic updates when using ClickTwice – MSI-based web deployment technology (this technology is closely tied with Add-in Express).

Before you use the features described below, make sure your add-in doesn’t contain CheckForMsiUpdates calls!

Creating an add-in installer

You start with creating a setup project as described in section Deploying a per-user Office extension via an MSI installer of the Add-in Express manual. If you deploy a per-machine add-in, see section Deploying a per-machine Office extension via an MSI installer instead.

When the setup project is ready, you publish it using the ClickTwice publish wizard. Note that publishing with ClickTwice creates files, which you need to copy to the location accessible by the users of your add-in; the publisher dialog won’t copy the files for you.

Publishing the installer

To use automatic updates, click the Preference button (see the screenshot above) and tick the Enable automatic updates flag in the Preferences dialog window:

Setting up automatic updates

The Preferences dialog allows choosing these options:

  • You may prefer to check for updates when the host application starts or closes.
  • Alternatively, updates can be checked in the background in the specified intervals.

Publishing the add-in installer

At this point you can publish the add-in installer. When you do this, Add-in Express creates the MSIPublish folder within the add-in project folder. Now you need to copy all of the files and folders from the MSIPublish folder to the location accessible to end users via the URL specified in the Installation URL field (see the first screenshot).

The files and folders within the MSIPublish folder are described in Files generated by ClickTwice.

The main file is called downloader. If no prerequisites are specified, it downloads the .MSI file from {Installation URL}/{Language code}/{Version} and runs it. If prerequisites are specified, it launches setup.exe located in the prerequisites folder, waits for the prerequisites to get installed; and then downloads and runs the .MSI. The file name of the downloader is set to the name of your project, such as myaddin1.exe.

Installing the add-in

Provide the end user with the URL pointing to {Installation URL}/{Language code}/{Version}/{downloader file name} and let them download and run this file. Starting it installs prerequisites (if specified) and runs the add-in installer.

Creating an update

Modify the add-in project and change its version. Update the setup project and change its version. Create an installer for the updated setup project and publish the installer. Copy all the files from the MSIPublish folder to the location that the users access via the URL specified in the Installation URL field.

Automatic updates

When you publish the add-in, a set of important files is created in folder MSIPublish/{Language code}/{Version}/updater. These files are the updater application and its configuration file. When installing the add-in, the downloader also downloads the updater application; the updater checks for updates as specified by the developer. The settings of the updater application are available for the developer on the Preferences dialog:

Setting up the updater application

When the updater detects an update, it creates an icon in the notification area and displays the balloon tip:

'Update is available' Notification

In the screenshot above, you see the icon specified in the Publish dialog.

Clicking the notification icon produces the following dialog (this form is fully customizable via the OnUpdaterUICreate event of the ClickTwice module):

Updater form

Clicking the Download button downloads the downloader for the new version and starts it. The downloader checks that the host application(s) is closed and starts the installer.


  • Eugene says:

    Looks great! Can’t wait to try it out.

    One minor thing is to consider – make all windows theme aware. Built-in tools should correspond to the host UI.

  • Andrei Smolin (Add-in Express Team) says:

    Hello Eugene,

    Thank you for the suggestion!

  • Jitu Patidar says:

    Seems a great feature…

  • mikky says:

    It seems great,thank you for your sharing.

  • Duke Vukadinovic says:

    I’m sure that many will disagree with me but I really like the idea that Microsoft Office 2016 is running on an auto-update feature, similar to Windows 10. It’s a quite handy feature for us who suffer from short term memory amnesia :)

  • Asim says:

    I am just having a small issue, windows is showing ballon tips that Your update is available and when i download, it won’t start automatically.
    Is there any property i am missing?
    Please respond

  • Andrei Smolin (Add-in Express Team) says:

    Hello Asim,

    Is the host application started at this moment? Is the updater icon available in the tray area? What you get if you click (double-click) it? Please send a screenshot(s) and as many details as possible to the support email address; find it {Add-in Express installation folder}\readme.txt.

  • David says:

    This is great, except I can’t get passed the signing section of the MSI-based web deployment dialog box when trying to publish. I have a code signing certificate from GoDaddy that I use for all of my applications and have never had an issue. When I click “Select from Store” and select my certificate it gives a popup that says certificate not found in store. When I click “Select from File” and select the .p12 version of my certificate it gives a popup that says “Add-in Express for Microsoft Office and .NET: Arithmetic operation resulted in an overflow.” When I select the .pfx version of my certificate it gives the same popup. When I click “Create New” and make a new certificate I get the same popup when clicking “Publish”. I would really love to use this functionality, please help.

Post a comment

Have any questions? Ask us right now!