DotNetRussell
DotNetRussell

Reputation: 9857

Click once deployment not updating after Assembly info changed

So up until this point I have been using an updater I wrote for deployment across my company network. Enough people have asked me to switch to a clickonce updater so I am looking into it now. These are the steps I took to implement it.

  1. Removed my update logic from the solution
  2. Published my app and pointed the update path to a fully qualified shared network location
  3. Installed my app
  4. Ran my app
  5. Changed the Assembly version and file version in the solution
  6. Published the new version to the update path
  7. Attempted to start app but didn't get a prompt to update.

What am I missing?

Upvotes: 3

Views: 3568

Answers (2)

DotNetRussell
DotNetRussell

Reputation: 9857

So the Answer is I was pretty simple but it should be documented on Stack for clarity.

Everything I am about to post is here. http://msdn.microsoft.com/en-us/library/1zyc39fb(v=vs.80).aspx

The problem that I was having was that I kept publishing to the same location when in reality after you do your initial publish, you need to ONLY publish to the update location.

For example: What I was doing:

Version 1 is published to c:\ver1\ With and update location of c:\ver1Update\

Version 2 is published to c:\ver1\ With nothing put into c:\ver1Update\

The correct way to do it (at least to make it update):

Version 1 is published to c:\ver1\ with an update location of c:\ver1Update\

Version 2 is published to c:\ver1Update\ with an update location of c:\ver1Update\

This was the fundamental difference and allowed it to update

This can all be done by right click on your project and selecting properties. Then clicking on the publish tab.

Hopefully this helps someone else confused in the future about this process.

Upvotes: 0

Marty
Marty

Reputation: 7522

There are a couple of steps you may have missed:

  • Did you enable "The application should check for updates" and " Before the application starts" in the ClickOnce update settings (in the Publish tab in Visual Studio)?
  • Did you update the ClickOnce 'Publish Version' before publishing your new version (it's also in the Publish tab in VS)?

Upvotes: 7

Related Questions