17

I need to keep a program I've written up to date, this will happen frequently over the next year or so, this will need to be done over the Internet. Where would you suggest I start, are there any common techniques? Any suggestions welcome.

Thanks

  • 2
    You can try Autoupdater.NET from [codeplex](http://autoupdaterdotnet.codeplex.com/) I developed it my self and it works very well in my applications. You just have to add one line in your code and its done. – Ravi Patel Jun 10 '12 at 04:36
  • [This article](https://omaha-consulting.com/best-update-frameworks-for-windows) gives an overview of the most popular solutions. – Michael Herrmann Jun 23 '20 at 16:46

4 Answers4

12

Fairly well is not good enough :)

NAppUpdate is an open-source library I wrote to address just this. The general idea is to have the greatest flexibility, at the lowest overhead possible.

So, integration is super-easy, and the library does pretty much everything for you, including synchronizing operations. It is also highly flexible, and lets you determine what tasks to execute and on what conditions - you set the rules. Last by not least is the support for any updates source (web, BitTorrent, etc) and any feed format - whatever is not implemented you can just write by yourself.

Cold updates (requiring an application restart) are also supported, and done automatically unless "hot-swap" is specified for the task.

This all boils down to one DLL, less than 70kb in size.

More details at http://www.code972.com/blog/2010/08/nappupdate-application-auto-update-framework-for-dotnet/

Code is at http://github.com/synhershko/NAppUpdate (Licensed under the Apache 2.0 license)

synhershko
  • 4,472
  • 1
  • 30
  • 37
9

ClickOnce is perfect for this sort of scenario.

Matt Hamilton
  • 200,371
  • 61
  • 386
  • 320
  • Problem with ClickOnce as I've just found out to my cost is that is won't work in a Terminal Services environment - see link here:http://support.microsoft.com/kb/2020945 – Swomble Feb 05 '13 at 10:12
7

There is this great framework called NetSparkle and also this DotNetUpdater

I haven't used them yet but hope to do so very soon. You can try it out.

Eran
  • 387,369
  • 54
  • 702
  • 768
  • 29
    So in other words, you just googled and found out about them. – Zoran Pavlovic Oct 22 '12 at 06:53
  • That's the problem with providing links only: over time they're broken. @Shaikh Mohd. Nadeem, is DotNetUpdater still available nowadays and where to get information? (Google was not able to help on this occasion) – Alex Sanséau Nov 23 '17 at 10:01
3

ClickOnce is a good solution, but if you wish to have total control then you can roll-your-own. I would suggest polling a webservice to find if there are later versions available, downloading required files to a side-by-side directory, and using a launcher (or updating a shortcut) to automatically launch the latest version.

This is a little complicated, but caters for situations where the application may be running, and can therefore not be overwritten.

Fritz H
  • 3,539
  • 2
  • 26
  • 37