Fileversion mismatches Assembly version when using wildcard

L

Lucvdv

In my assembly.vb files, I'm using the revision/build wildcard style:

<Assembly: AssemblyVersion("3.0.*")>
<Assembly: AssemblyFileVersion("3.0.*")>

This onkly seems to work in projects that were originally created under
VS.Net 2003. The proper version number is generated as expected, assembly
version and file version of the compiled executable are both
3.0.xxxx.yyyyy.

In projects created under VS.Net 2005, the assembly version "listens" to
the wildcard character, but the file version of the compiled executable is
always 3.0.0.0.

At least I /think/ what version of Visual Studio the project was originally
created in is what makes the difference, I don't see anything else.



Furthermore, the VS.Net 2005 UI (project settings, "Application" tab,
"assembly information" button) wouldn't let me enter the wildcard: I had to
edit the assemblyinfo.vb file manually.

Yet the fact that you can use the wildcard is documented in the comments in
the auto-generated assemblyinfo.vb, and after changing it manually the UI
shows it just the way you'd expect it (i.e. 3rd version box an asterisk,
4th box empty).
 
L

Lucvdv

In my assembly.vb files, I'm using the revision/build wildcard style:

<Assembly: AssemblyVersion("3.0.*")>
<Assembly: AssemblyFileVersion("3.0.*")>

This onkly seems to work in projects that were originally created under
VS.Net 2003. The proper version number is generated as expected, assembly
version and file version of the compiled executable are both
3.0.xxxx.yyyyy.

In projects created under VS.Net 2005, the assembly version "listens" to
the wildcard character, but the file version of the compiled executable is
always 3.0.0.0.


As often, I look straight through the answer for an hour as if it's
invisible, post a quetion about it, and then only a few minutes later see
what I was overlooking.


In VS.Net 2003 projects there's only one line, also after conversion to
VS2005:
<Assembly: AssemblyVersion("3.0.*")>

File version is automatically the same.


In VS.Net 2005 projects, there are two lines:
<Assembly: AssemblyVersion("1.0.0.0")>
<Assembly: AssemblyFileVersion("1.0.0.0")>

Replacing the final "0.0" in the first line works, in the second line it
doesn't. You have to delete that line or comment it out to make it work.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top