Question

Setting the scene:
My asp.net web application carries a version number which is incremented during every release. We're releasing every week internally for our test team and after four weeks or so to our client.

The question:
I want to include the version number on our application. What methods have you used so that your web app carries the version number? meta tag? simply added it to the footer?

Was it helpful?

Solution

If you are in contact with the client a lot (for bug fixes or changes) you should keep the version number in a place that is easy to find (such as the footer). You will find yourself asking the client what version they are running, if they cannot find it it is frustrating for both the client and the support staff.

Make sure your footer is a user control or that the version is stored in either a database table or a resource file so that you update once rather then going through each page updating. My recommendation is a user control and if you want to track versioning store the version numbers in a database and read it into your user control.

You can take the MS route of doing a help->about given a menu and displaying the version number in say a js popup or on another page.

If for some reason you do not like the version number on a footer or even a help menu popup and you do not deal with the client regularly you can put it as meta data or in the source code of your HTML.

OTHER TIPS

We have some information page where we display the version number (SaaS application).

But seriously, with web software version numbers are irrelevant. It is the point of migrating to the web - so that the users finally forget about those versions, updates, service packs etc. Otherwise the idea of a constantly updated web application (perpetual beta) is not really grasped by either party.

In some Projects we added the Version number to the footer. We displayed the Assembly (any of our Assemblies) Version number.

With that method we did not have to care about the text in the footer as long we incremented the Assembly Version.

Assembly Version was extracted with Reflection.

I've seen a lot web applications (and websites) I've seen that add the version number as a comment within the generated HTML. The BBC is one of them - view the source and you'll see <!-- Barlesque v34.8 --> in the header. (Barlesque is the BBC's layout system.)

Check out the code posted here. It will gather and display the .NET Framework version info. Anytime you need the version information of the current assembly, you can use

Assembly.GetExecutingAssembly().GetName().Version

Similarly, to get the version info for a particular assembly, you can either reflect directly on the assembly, or simply use a class in the assembly

typeof(ClassKnownToBeInTheTargetAssembly).Assembly.GetName().Version

where ClassKnownToBeInTheTargetAssembly is a class declared in the assembly you want the version info for.

BTW, these comments assume that the assemblies are signed.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top