AndyC
Posts: 11
Joined: Sat Jan 06, 2007 12:51 am

Updater problem with latest version

I am experiencing two problems using the updater with the current build.

First problem:
I have a scheduled task to check for updates every day.
This runs and reveals that a new update is available.
The update is a complete new version, not an upgrade.
The update has a version number bump from say 1.5.6 to 1.5.7

On XP, the installer app runs assuming you want to install the new update, HOWEVER, it does not download the new update, it re-runs the LAST update stored in Documents and Settings\....\updates\update\progname.msi

Second problem:
The updater .ini file will attempt to close the main app program if you are running it and checking for an update. This works.
When the updater is run from the program itself, at the end of installation, it will prompt whether you want to launch the application again.
Unchecking the box STILL launches the application regardless.

Both of these issues appear to be new to the .8 build as I haven't seen them prior.

Thanks.
gigi
Posts: 2103
Joined: Tue Apr 11, 2006 9:55 am
Contact: Website

Hi,

This is because you don't change the update section for the new update. The section key in the updates.aiu file is unique with each update. So when you create a new update do not re-use an older update section, create a new one:
http://www.advancedinstaller.com/user-g ... ation.html

Regarding the second problem, if you use "Auto Close Application" feature note that you have the option to disable auto restart (which is enabled by default): http://www.advancedinstaller.com/user-g ... ialog.html

Please let me know if you encounter any problems.

Regards,
Gigi
______________
Gheorghe Rada
Advanced Installer Team
http://www.advancedinstaller.com
AndyC
Posts: 11
Joined: Sat Jan 06, 2007 12:51 am

Gheorge,
The updates.aiu is being built by the installer and I haven't changed the way this is modified from release to release.

Example:
;aiu;

[update]
Name=Progname 1.5.7
URL=PathToMSIonServer
Size=1234567
ReleaseDate=26/03/2007
MD5=longhexstring
FilePath=[APPDIR]ProgName.exe
Version=1.5.7
Description=Enhanced for Vista
AutoCloseApplication=[APPDIR]ProgName.exe

In the above example I gave, the Name, Size, ReleaseDate (should this be in European format for the US?) MD5, and Version all change between each point release and this has worked fine in the past.
As I stated the updater detects a new version, but does not download it and re-runs the last downloaded update on the local PC.

My bad on the second reported problem, as I was not preventing auto-restart.

Thanks
gigi
Posts: 2103
Joined: Tue Apr 11, 2006 9:55 am
Contact: Website

Hi,

A new update requires to create a new section in the updates.aiu file (choose "New Update" in the "Updates Configuration Project"). The behavior you encounter is due to the fact that you re-use an old section (items in the "Organization" tree represents sections in the updates.aiu file) when you create a new update.

AI documentation states:
There is a section for each available update and, optionally, a special section for general configuration, named General. The name for a section must be unique; the comparison is done case insensitive. A section name must contain only letters and digits, no special characters. The updates should be placed in descending order, with the newest first.
You can read more here:
http://www.advancedinstaller.com/user-g ... ation.html

The Updater downloads the update file in the downloads folder (specified in the updater.ini file) under a folder with the name as the section and if the update it's already downloaded it's executed form there (will not be downloaded again).

So when you create a new update choose "New Update" from toolbar or context menu. Also you can specify relationships between updates like Replaces or Dependencies.
http://www.advancedinstaller.com/user-g ... -page.html

Regards,
Gigi
______________
Gheorghe Rada
Advanced Installer Team
http://www.advancedinstaller.com

Return to “Common Problems”