japandave1
Posts: 5
Joined: Thu Oct 28, 2021 3:12 am

Updater not working as expected?

Thu Oct 28, 2021 3:38 am

Hey,

I am having an issue with the updater that it is not picking up that an update is needed.
This is my first time doing this so I probably have screwed something up.

What I have done so far,
Creating the MSI /.exe file
1. Created new project in professional installer with .NET Application and selected create MSI file
2. Entered necessary details in Product details
3. Selected folder where the application is
4. Set install parameters
5. Set registry for product version registration
6. Saved and build

Installed fine and runs
Creating the Updater project,
1. Selected Updates and create project and select the output udater file as a .txt file
2. Updates in accordion navigation pane: Properties tab: set URL etc
3. Update installer tab: set file path and Product version ( same as above)
4. Update and Install Detection tab: Set registry value as follows `HKUD\Software\My_Company\My_App\Version` and expected value set as old version number
5. Update targets tab: Added target for all platforms
6. Save and build and corresponding .txt file is created with necessary information in the .txt file.

Now when running the installed app it never picks up the the update and I am wondering if it is due to my file naming???
I using a Network Sever with file address something like this `\\XXX.XXX.X.XXX.My_Update_Folder.My_App.exe`. However when entering a folder like this you are prompted to enter the correct suffix to the file path, so I used this, `file://\\XXX.XXX.X.XXX.My_Update_Folder.My_App.exe`.

Is the file path structure incorrect? Also, is the output file name case sensitive?

Cheers Dave

Liviu
Posts: 600
Joined: Tue Jul 13, 2021 11:29 am
Contact:  Website

Re: Updater not working as expected?

Fri Oct 29, 2021 3:59 pm

Hello Dave and welcome to our forums,

I've just tested this and works as expected on my machine. I think you may be missing some steps from the updater process.

Please have a look on our Using the Updater for local deployment article.
Is the file path structure incorrect? Also, is the output file name case sensitive?
The file structure is correct and the file name is not case sensitive.

These are the steps I followed:

1. Create your original package. I created on my machine a local network shared folder.
In the "Updater" page on “Updates configuration file URL” option I have: file://\\DESKTOP-MUA5C29\updater\updates.txt

2. Now from the above project create your update package project and save it with a different name. Change the product version and also generate a new product code, all the steps are explained in the above tutorial. Build the project and move your v2 package to your network location.

3. Create the Update project and add a "New Update" which points to your v2 from the network location like this:
UpdateProject.png
UpdateProject.png (44.34KiB)Viewed 6324 times

4. Build the project. Move the updates.txt to your network location and also make sure there is also the v2 package.

I think you forgot to add the updates.txt or the update package to the network location. Make sure you add them in the location you entered in the URL in projects.

Let me know if that helped!

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

japandave1
Posts: 5
Joined: Thu Oct 28, 2021 3:12 am

Re: Updater not working as expected?

Fri Nov 05, 2021 9:26 am

Hey Liviu,

I did all that you said and the `Updates.txt` file is where it was supposed to be. Still ,it does recognize the text file and no update is performed.
I am correctly point the `Updates.txt` file to the correct updated version in the `Updater` project. All paths have been double and triple checked to account for spelling mistakes etc.

In the end the only way I could get this to work was placing the below code in the project itself which is not ideal I guess.
C#

Code: Select all

Process p = new Process();
            p.StartInfo.FileName = @"updater.exe";
            p.StartInfo.Arguments = "/justcheck";
            if (p.Start())
                p.WaitForExit(30000);

            if (p.ExitCode == 0)
            {
                p.StartInfo.Arguments = "";
                p.Start();
                return;
            }
Cheers Dave

Liviu
Posts: 600
Joined: Tue Jul 13, 2021 11:29 am
Contact:  Website

Re: Updater not working as expected?

Fri Nov 05, 2021 10:49 am

Hi Dave,

This is quite strange.

In order for us to further investigate this, can you please send us the following resources:

  1. the old .AIP file
  2. the new .AIP file
  3. the Updates Configuration Project
  4. a download link for your old setup package
  5. a download link for your new setup package
by email to support at advancedinstaller dot com

Or, even better, could you please create a sample project (v1, v2 and update project) that reproduces this and forward it to me together with a test case which I can follow in order to reproduce the problem?

Best regards,
Liviu
________________________________________
Liviu Sandu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”