Windows Installer, Java Installer, Freeware Installer
Home|Contact|Site Map|TOC|Search
Download  Features   Java  Licensing  Purchase  Testimonials  Support  Forums

Using The Auto Updater

This tutorial will guide you step by step in creating and maintaining an install package that uses the Advanced Updater.

We will create an install package for the "story.txt" file that we used in the Simple Installation tutorial.

ImportantIf you have an EXE file at your disposal to which you can easily change the version you could use it instead of the "story.txt" file to complete this tutorial.

  1. Creating the original install package.
  2. Managing the first patch.
  3. Managing the second patch.
  4. Managing a major upgrade.
  5. The End

Creating the original install package.

Create a professional project.

Now create the install package following the same steps as described in the Simple Installation tutorial, but don't build the package yet.

After adding the files to the package it is time to add the auto-update functionality.

UpdaterSwitch to the Updater Page by selecting it in the left-side panel.

Select the "Enable Advanced Updater" checkbox.

Now, you will have to reserve on your site a location for the updates configuration file. You will create this file when the first update will be released. For now, you just have to input the location. Let's suppose you have chosen this location:

http://www.myupdateslocation.com/download/StoryUpdates.txt

Enter it in the "Updates URL" field.

Updater Page

NoteFor deployment simplicity reasons we have used TXT as the extension for the updates configuration file. If you want to use other extensions you might need to configure the MIME types on your server to recognize that extension.

In order to be able to launch the Advanced Updater, create a desktop shortcut that will point to the updater.exe file in the package.

Files and FoldersGo to the Files and Folders page. Right click on the "updater.exe" file and choose "New Shortcut...". In the newly appeared dialog edit the fields like in the following screen-shot.

Updater Shortcut

ImportantIf you are using an EXE file to go through this tutorial instead of creating a shortcut please see an example on how to integrate the updater with your application.

Build Save and build the package.

InstallInstall the package.

UpdaterClick on the desktop shortcut. Naturally, no updates are found.

Managing the first patch.

Modify the story.txt file by changing a few words. Let's say that these are some spelling mistakes you have fixed. Suppose that it's new size is 1234. You want to release a patch to fix this problem.

NoteIf you are using an EXE file, change it's version.

For a detailed description on how to create this patch see the Patch Authoring tutorial. Upload it to the designated URL location.

After creating the patch is time to create the StoryUpdates.aiu file on the server so the updater will know that new updates are available. Create a new Updates Configuration Project and add the first update as shown in the updates tutorial. Build the project and place the resulted file it on the URL location you specified earlier.

UpdaterClick on the desktop shortcut. You will notice that a new update is found. Download and install it. Check for updates again. Notice that the Auto Updater is not shown anymore.

Managing the second patch.

Modify the story.txt file by adding a new paragraph. It's new size is 2345.

NoteIf you are using an EXE, again change it's version.

You need to release a new patch. Create it following the same steps as before. Upload the patch.

The updates configuration file must be edited too and add the data about this new release. Modify the updates project as shown in the updates tutorial.

UpdaterCheck for updates again. You will notice that the first update is not visible anymore, only the second one. Install the update.

Managing a major upgrade.

At this time let's say you want to add a couple of more files to the package. A major upgrade and a version change is needed.

NoteIf using an EXE, change it's version.

Create two more text files in the same way you did with "story.txt". Name them "contents.txt" and "aboutme.txt". Modify the previous created package. Add the rest of the files and change it's version to 2.0. Answer "Yes" when asked whether to generate a new product code. Again, upload the MSI file.

Modify the updates project to include information of this major update. Please see the updates tutorial for reference.

UpdaterDouble click on the shortcut, download and install the MSI file.

The End

This concludes our tutorial. If you find this tutorial too complicated or your project doesn't work as expected, you can try our step by step instructions.

NoteIn this tutorial we used as a criteria for detecting whether an update is installed the size of the file. This is because the main file from the package is a TXT file which has no version. When using the updater with a real application it is recommended that you use as a criteria the version of a file from the package. This version is supposed to change at every new release. For an example of a configuration file that uses this criteria please see: Updates for an EXE

Privacy Policy | Windows Installer | Search Engine Ranking | Link Analyzer