Create one level of indirection.
Right now, you have separate URLs for v.1, v.2, v.3.0, v3.1, etc. No wonder, you cannot guarantee that your application can find the latest URL, or any other URL with the update except the one which comes with your application. This problems is solved in a really simple way.
Add one more URL, a
fixed one, which you never modify. At this URL you should place some file which gives you the URL of the latest update or, if you want your application to choose from a set of updates, all the URLs of all the updates. The best way to do so would be put this information in some XML file. For example:
="1.0"
<MyApplicationUpdates>
<versions>
<version verisionid="1" url="http://www.mySite.net/myApplication/updates/v.1" />
<version verisionid="2.0" url="http://www.mySite.net/myApplication/updates/v.2.0" />
<version verisionid="3.0" url="http://www.mySite.net/myApplication/updates/v.3.0" />
<version verisionid="3.1" url="http://www.mySite.net/myApplication/updates/v.3.1" />
</versions>
</MyApplicationUpdates>
As you can see, the format of versions and respective URLs can be different, but your XML file would provide all the information. It can be any other kind of file with the same information, but XML is the most convenient; it is standardized; and .NET FCL provides different classes to parse it.
Now, the procedure for publishing updates will be this: first, you develop a new version of the product under the new version of its assembly (assemblies) and put on your site. If at this moment someone initiate update from your application, the XML will still provide the previous version as the latest accessible to the user. Then you need to update the XML by adding one
<version>
element to it. Then your application will get it: it will first access XML, parse it, find the latest version and then will download the required version of the product using URL obtained from your XML.
—SA