Questions tagged [assemblyversionattribute]

The AssemblyVersionAttribute class is used by the .NET framework to specify the version number of an assembly.

The AssemblyVersionAttribute class is used by the .NET framework to specify the version number of an assembly.

26 questions
45
votes
6 answers

.NET: Large revision numbers in AssemblyVersionAttribute

We have the convention of versioning our builds as [major].[minor].[micro].[revision], e.g. 2.1.2.33546. Our build-script automatically updates an AssemblyInfo.cs file containing [assembly: AssemblyVersion("x.y.z.w")] in order to embed the…
Rasmus Faber
  • 48,631
  • 24
  • 141
  • 189
31
votes
1 answer

CS1607: The version specified for the 'file version' is not in the normal 'major.minor.build.revision' format in .NET

I am trying to set my AssemblyVersion and AssemblyFileVersion attributes in my project like so: [assembly: AssemblyVersion("3.0.*")] [assembly: AssemblyFileVersion("3.0.*")] but I get this warning: CS1607: Assembly generation -- The version…
Sheridan
  • 68,826
  • 24
  • 143
  • 183
25
votes
3 answers

GetCustomAttribute() returns null for AssemblyVersionAttribute

I'm adding an About dialog to my .NET application and I'm querying the assembly's attributes for information to display. When I attempt to retrieve my assembly's AssemblyVersionAttribute using GetCustomAttribute() it returns null: // Works…
sourcenouveau
  • 29,356
  • 35
  • 146
  • 243
17
votes
1 answer

What is the formula in .NET for "*" (wildcard) version numbers?

Say I have a version number 1.5.* that is compiled as 1.5.4735.28467. What is the formula for getting 4735 and 28467?
Jonathan Allen
  • 68,373
  • 70
  • 259
  • 447
11
votes
5 answers

What is the AssemblyFileVersion used for in C#?

In the assemblyInfo.cs I have AssemblyVersion and AssemblyFileVersion. Normally I just increment the AssemblyVersion like this. 1st digit: Major change 2nd digit: Minor change 3rd digit: bug fixes 4rd digit: Subversion revision number However, I am…
ant2009
  • 27,094
  • 154
  • 411
  • 609
7
votes
1 answer

Assembly version ".001" becomes ".1"

In WinForms I have an AssemblVersion [assembly: AssemblyVersion("01.01.01.002")] However when the splash screen comes up it completely ignores the zeros showing: 1.1.1.2 as the version which is very inconvenient since later I will actually want…
Nickolay Kondratyev
  • 4,959
  • 4
  • 25
  • 43
5
votes
1 answer

How can I get the build number of a Visual Studio project to increment?

Why does building a project in Visual Studio not increment the Build number? I've got this in AssemblyInfo.cs: [assembly: AssemblyVersion("1.5.*")] ...and this in frmAbout's constructor: Version versionInfo =…
4
votes
4 answers

AssemblyInfo build number not updated

I have the following code in AssemblyInfo.cs: [assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyFileVersion("1.0.0.0")] I'm trying to make sure the Build Number changes each time I build/rebuild my project. But, in that case it doesn't. Only…
4
votes
2 answers

VB.Net - What is the difference between AssemblyFileVersion & AssemblyFileVersionAttribute and AssemblyVersion & AssemblyVersionAttribute

I've inherited a VB.Net codebase which was VB 2005 and upgraded to VB 2008 consisting of around 100 projects I'm trying to re-version all of the components but have discovered some of the AssemblyInfo.vb files have an AssemblyFileVersion entry and…
4
votes
2 answers

Create dynamic Assembly Version including date and random revision number

I'm looking for a way of creating a dynamic Assembly Version for my ASP.NET MVC5 solution so that it would follow the format: YYYY.M.D.XXXXX For example: 2014.7.25.45261 Ideally I would like to do the following in AssemblyInfo.cs: DateTime dt =…
Curtis
  • 101,612
  • 66
  • 270
  • 352
4
votes
2 answers

Assembly Version Checking in .Net

I am trying to fully get my head around assembly versions and strong names in .NET I found This Assembly Versioning Article stating that only Major.Minor.Build is used in version matching. I cannot find anything that can confirm/deny…
Tyst
  • 861
  • 1
  • 11
  • 26
3
votes
3 answers

Version information missing from .NET assembly (Compact Framework 3.5/VS2008)

I am building an executable using VS2008 and .NET compact framework 3.5, targetting Windows Mobile 6 professional, but whenever I compile the project, everything that I have specified in the AssemblyInfo.cs file is ignored. I have done this many…
Martin Robins
  • 6,033
  • 10
  • 58
  • 95
2
votes
1 answer

Incrementing build number with Hudson build

Here is what I am trying to achieve. I currently use Hudson build to do builds for me on a remote computer. I currently have to open my solution and manually update the [assembly: AssemblyVersion("1.2.6.190")] numbers in two files and then commit my…
2
votes
3 answers

AssemblyFileVersion attribute is being ignored

I am having a problem getting the AssemblyVersion to be different from the AssemblyFileVersion attributes in a class library I am working on. So, I've tried creating an empty (apart from Class1.cs) class library to see if it's a setting somewhere,…
Antony Scott
  • 21,690
  • 12
  • 62
  • 94
2
votes
2 answers

How to avoid repeated constant string in .NET AssemblyVersion and AssemblyFileVersion

In a C# project, we increment versions manually and have a top-level file MyAssemblyInfo.cs containing [assembly: AssemblyVersion("31.1.13")] [assembly: AssemblyFileVersion("31.1.13")] [assembly: AssemblyInformationalVersion("31.1.13-V1.0.0")] I'd…
Chris
  • 4,133
  • 30
  • 38
1
2