0

I have a .NET ClickOnce application. Sometimes the installation of a new version fails and user cannot launch the application any more.

When the failing app is uninstalled on a local computer and installed anew, then everything is ok.

When I rollback to the previous version (from Windows control panel) it is also working, but after the rollback I am unable to retry the installation of the failed update. It means, that after a rollback the newer version (that is actually published on server) is ignored by the client even if I try to update it explicitly by the code. The code I use is similar to this example http://msdn.microsoft.com/en-us/library/ms404263.aspx.

Is there any way how to retry the installation of a previously rolled back update?


I have tested it now with another application that is also deployed with ClickOnce to IIS server directly from Visual Studio. The behavior was little different. When I rolled the app back then after launching it, it did offer an update once but after refusing the update then it is not offered during startup any longer.

So it seems to me now that perhaps launching the app from the installation URL and not from the shortcut might do the trick. But to be sure I will wait until the update fails again.

Vojtěch Dohnal
  • 7,867
  • 3
  • 43
  • 105
  • Don't know the answer to your question, but I do know that the WiX enthusiasts turn up their noses at ClickOnce and say it has certain intrinsic problems. http://www.stevestreeting.com/2013/05/12/friends-dont-let-friends-use-clickonce/ Sorry, I thought I could find other links but couldn't - I'm sure I've seen ClickOnce discussed (rather negatively) on the WiX mailing list, etc. – RenniePet Sep 09 '14 at 10:25
  • @RenniePet Yes I have read that article when I was deciding over the app updates technology. Still for me it was the simpliest approach and do not have really big troubles with it. – Vojtěch Dohnal Sep 09 '14 at 10:28
  • Click once should be checking the version numbers and if the server contains a newer (higher) version it should download it. Are you certain the version number on the rolled back version is less than the version on the server? – Phil Sattele Sep 09 '14 at 15:08
  • @pSattele: Yes, I am. The problem might be connected with this http://stackoverflow.com/questions/5106000/clickonce-update-cancelled-by-user-and-it-never-asks-for-update-again. But thanks anyway. – Vojtěch Dohnal Sep 09 '14 at 18:13

1 Answers1

0

Today I got the same problem with ClickOnce update as described here: ClickOnce: Value does not fall within the expected range

I was able to rollback and then install the new version using theese steps:

  • From the control panel Add/Remove programs I did rollback to the previous version.
  • Then opened the install URL in Internet Explorer manually and the new version got downloaded and installed and working OK.
Community
  • 1
  • 1
Vojtěch Dohnal
  • 7,867
  • 3
  • 43
  • 105