Click here to Skip to main content
15,389,594 members
Articles / Programming Languages / C#
Posted 30 Jun 2013


97 bookmarked

HiUpdate tools - Automatic application updates

Rate me:
Please Sign up or sign in to vote.
5.00/5 (20 votes)
19 Sep 2013CPOL4 min read
HiUpdateTools is a easy tools to use publish new version of your application

Every programmer and software creator solves one question which is how to distribute new versions of his own application. There are several ways how this can be performed, such as ClickOne from Microsoft that is integrated directly into Visual Studio or you can write similar tool by yourselves. I briefly summarize the advantages and disadvantages of ClickOne. The tool is very simple and debugged and fully integrated into Visual Studio. Unfortunately ClickOne simplicity is also its weakness. The system is not designed for larger projects, and that is for several reasons: nobody can control where the application is installed, update from ftp server cannot be performed, and publishing is not the fastest one.

Therefore, some of the programmers write their own updater. Of course, if they do not want to pay for some paid tool such as (wyBuild, AppLife Update Engine). This led me to the idea to write such update tools that takes the best of ClickOne (Integration into Visual Studio, Differential updates, etc.) and at the same time a programmer will have everything under his control. And that is how tool, which I called HiUpdateTools, has been created.

The main features of HiUpdateTools plug-in into Visual Studio

  • Integration into Visual Studio (directly from VS you can administrate and publish new versions)
  • Publishing of different types of projects WinForms, WPF, WebApplication (in preparation)
  • Publishing in several ways (ftp, file)
  • Each file is zipped before sending (less data is transmitted)
  • The files are stored separately into the destination location so that only new files can be downloaded
  • Checking the existing version on a server
  • For each published version it is possible to attach information about changes
  • Automatic Build in Release mode and version change in AsemblyInfo.cs
  • Possibility to choose which projects will be built and which versions will be updated   

The main features of HiUpdateTools.Client - client side 

  • Downloading from multiple sources (ftp, file, http, https)
  • Client for WinForm, WPF 
  • Easy integration into applications
  • Possibility to turn on automatic updates (without confirmation)
  • Differential update (only changed files are downloaded)
  • The application runs through your exe file (there is no UpdateAndRunAplication.exe)
  • Checking multiple launches of your application
  • Storing the encrypted password in the client configuration file 

Using in Visual Studio 

How to publish your application 

After installing VSX pug-in into Visual Studio, the new button which is used for calling up a dialog for setting and publication of your application, will appear in the context menu above your project.

Here you set the Application name, the Application type, the Version. You can also set the location of the server where the application should be published. 

In the Client config tab you can prepare and export the XML configuration for your application. 

Once everything is set up, you can get your application published for the first time by clicking Deploy button. In the destination location there should be something like this:

In ServerConfig.Xml file there is stored information about the version, files that are included in the current version. In the individual sub-folders there are stored zipped files for each version. 

Integration into your application 

Add into your application HiUpdateTools.Client.Win.exe and ClientConfig.Xml references and then a static property in the Program.cs class.

public static string[] Args { get; set; }  

Then fill this property in a Main method.

static void Main(string[] args)
    Args = args;
    Application.Run(new MainForm());

Once this is done, just capture MainForm Load event and add the following code there.

if (!Program.Args.Contains("/noupdate"))
 using (UpdateChecker checker = new UpdateChecker("ClientConfig.xml",
       if (checker.Check())

Then, when you run the application and a new version of your application will be found on the server, your application will be terminated and the HiUpdateTools.Client.Win.exe application and update operation will then be launched (in the case of setting the AutoUpdate) or you will wait for launching by clicking Update button.

For more information about the project, see


  • Fixed bug when deploy app to ftp server 
  • Added support for Visual Studio 2010 (new VSX file) 
  • The upgrade process has been moved to block TryCatch 
  • Added Error Form to display the error and send the report an error 
    •  Fix remove partially unzipped files
    •  Fix exception throw in Win client app 
    •  Generate ClientConfig.xml and adding to the project
    •  Set ClientConfig.xml option "CopyToOutputDirectory"= Copy if newer
    •  Fix client path not ending the backslash 
    • Add Client assembly to VSX package
    • On first use, the tool is added to the reference to the client assembly
    •  Fix client application
      • Multi-instance application
      •  Run single instance of update application 
  • First release version on 30 June, 2013
    • Add support WPF client
    • Move  publish action into separate thread  
    • Change coding of config file on the UTF-8


    This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


    About the Author

    Josef Andrys
    Software Developer
    Czech Republic Czech Republic
    No Biography provided

    Comments and Discussions

    QuestionVS 2010 Ultimate version problem Pin
    goldorakiller21-Nov-13 3:28
    Membergoldorakiller21-Nov-13 3:28 
    QuestionVS 2013 support Pin
    khoirom31-Oct-13 16:53
    Memberkhoirom31-Oct-13 16:53 
    GeneralMy vote of 5 Pin
    yimlu21-Sep-13 18:42
    Memberyimlu21-Sep-13 18:42 
    GeneralMy vote of 5 Pin
    fredatcodeproject21-Sep-13 12:22
    professionalfredatcodeproject21-Sep-13 12:22 
    GeneralDeploy button doesn't work Pin
    Oliver Klotz17-Sep-13 21:15
    MemberOliver Klotz17-Sep-13 21:15 
    GeneralRe: Deploy button doesn't work Pin
    goldorakiller20-Nov-13 13:00
    Membergoldorakiller20-Nov-13 13:00 
    Questionerror when extract zip file Pin
    khoirom31-Jul-13 22:53
    Memberkhoirom31-Jul-13 22:53 
    QuestionVS2010 support Pin
    wapwork30-Jul-13 0:32
    Memberwapwork30-Jul-13 0:32 
    AnswerRe: VS2010 support Pin
    Josef Andrys30-Jul-13 22:04
    MemberJosef Andrys30-Jul-13 22:04 
    GeneralRe: VS2010 support Pin
    wapwork30-Jul-13 23:14
    Memberwapwork30-Jul-13 23:14 
    GeneralRe: VS2010 support Pin
    smalltide31-Jul-13 0:39
    Membersmalltide31-Jul-13 0:39 
    GeneralRe: VS2010 support Pin
    Josef Andrys31-Jul-13 1:35
    MemberJosef Andrys31-Jul-13 1:35 
    GeneralRe: VS2010 support Pin
    smalltide31-Jul-13 4:40
    Membersmalltide31-Jul-13 4:40 
    GeneralRe: VS2010 support Pin
    Heinz.Schmidt25-Sep-13 22:00
    MemberHeinz.Schmidt25-Sep-13 22:00 
    GeneralRe: VS2010 support Pin
    Josef Andrys26-Sep-13 0:18
    MemberJosef Andrys26-Sep-13 0:18 
    I found a bug in the configuration of the test project. Try this configuration (HiUpdate.xml):
    <? Xml version =" 1.0 "?>
    <DeployConfig Xmlns:xsi="" xmlns:xsd="">
           <Name>HiUpdateTools.Client.Test.csproj</ Name>
           <WriteVerion>True</ WriteVerion>
         </ ProjectConfig>
       </ Projects>
       <ChangeLogs />
       <ApplicationName>HiUpdateTools.Client.Test</ ApplicationName>
       <DeployType>WinApplication</ DeployType>
       <Version> </ Version>
       <ServerPathType>File</ ServerPathType>
       <ServerPath>D:\Install</ ServerPath>
       <ServerAnonymous> False </ ServerAnonymous>
       <ServerUserName />
       <ServerPassword />
    </ DeployConfig>

    Or try creating a new project. It really does not list anything in Ouput window in VS? I like to help but I can not simulate it.
    GeneralRe: VS2010 support Pin
    Heinz.Schmidt26-Sep-13 1:24
    MemberHeinz.Schmidt26-Sep-13 1:24 
    GeneralRe: VS2010 support Pin
    Josef Andrys26-Sep-13 2:27
    MemberJosef Andrys26-Sep-13 2:27 
    GeneralRe: VS2010 support Pin
    Heinz.Schmidt26-Sep-13 2:36
    MemberHeinz.Schmidt26-Sep-13 2:36 
    GeneralRe: VS2010 support Pin
    Josef Andrys26-Sep-13 3:03
    MemberJosef Andrys26-Sep-13 3:03 
    GeneralRe: VS2010 support Pin
    Heinz.Schmidt26-Sep-13 3:14
    MemberHeinz.Schmidt26-Sep-13 3:14 
    GeneralRe: VS2010 support Pin
    Heinz.Schmidt27-Sep-13 0:00
    MemberHeinz.Schmidt27-Sep-13 0:00 
    GeneralRe: VS2010 support Pin
    Josef Andrys27-Sep-13 0:37
    MemberJosef Andrys27-Sep-13 0:37 
    QuestionHiUpdateTools.Client.Win has stop working Pin
    khoirom29-Jul-13 22:03
    Memberkhoirom29-Jul-13 22:03 
    AnswerRe: HiUpdateTools.Client.Win has stop working Pin
    Josef Andrys29-Jul-13 22:40
    MemberJosef Andrys29-Jul-13 22:40 
    GeneralRe: HiUpdateTools.Client.Win has stop working Pin
    khoirom29-Jul-13 23:25
    Memberkhoirom29-Jul-13 23:25 

    General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

    Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.