?
Solved

VB.Net Error setting auto increment in assembly version

Posted on 2006-10-23
8
Medium Priority
?
1,750 Views
Last Modified: 2008-02-07
Hi All,

I get this error when setting the assembly version to autoincrement in vs2005.

the AssembyInfo.vb file has the following:

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

The error (warning) is:


Warning      3      Possible problem detected while building assembly 'ATMS': The version '1.0.0.*' specified for the 'file version' is not in the normal 'major.minor.build.revision' format      
0
Comment
Question by:nzfire
  • 4
  • 4
8 Comments
 
LVL 13

Expert Comment

by:newyuppie
ID: 17793497
is your assembly strong named?
0
 
LVL 1

Author Comment

by:nzfire
ID: 17799014
Hi newyuppie,

Am new to .Net and this will be my first major app in vb.net, so excuse the ignorance, but please could you give me a bit of a run-down on strongly naming an assembly. I've heard of it, but don't know how it works.

Thanks
0
 
LVL 1

Author Comment

by:nzfire
ID: 17799256
Hi Again All,

I have read up on strong assemblies, naming and signing and have signed my assembly.

I still get the error.

By the way, if I go into Sign the Assembly and create a new key from the option to create a key or browse for a key, a dialog box appears which allows you to name the key and set the password.

In that dialog box, the fields are enabled, but I cannot type anything in there, but the paste function works. ???? Any ideas?

Thanks again
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
LVL 13

Expert Comment

by:newyuppie
ID: 17799351
if you are using vb2005 its actually very easy. you need to go to project properties (rightclick on the prohect name on the SOlution Explorer to the right and select properties).

on this new window, on your left you get different panes. go to the Signing pane and check "Sign the assembly". Then on the dropdown list select <New...> and create a new key with a password you provide. then save and compile. see if this resolves the assembly version issue.
0
 
LVL 1

Author Comment

by:nzfire
ID: 17799392
Yep, done that again and this time specified one with a password, but still get the same warning.

I am wondering if it is something to do with the format of the version string.

Here is the bit of the assemblyinfo.vb file

' You can specify all the values or you can default the Build and Revision Numbers
' by using the '*' as shown below:
' <Assembly: AssemblyVersion("1.0.*")>

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

<Assembly: NeutralResourcesLanguageAttribute("en-NZ")>
0
 
LVL 13

Accepted Solution

by:
newyuppie earned 2000 total points
ID: 17799522
yeah apparently AssemblyFileVersion does not do well with *
nevertheless, you can use the * thing in AssemblyVersion without problems. and from what i understand, AssemblyFileVersion defaults to AssemblyVersion, so maybe you can remove the <Assembly: AssemblyFileVersion("1.0.0.*")> alltogether and only keep the <Assembly: AssemblyVersion("1.0.0.*")>.

does that help?


from MSDN documentation "Understanding and Using Assemblies and Namespaces in .NET"
Table 1. Standard assembly attributes

Attribute Meaning
AssemblyCompany Company shipping the assembly
AssemblyCopyright Copyright information
AssemblyCulture Enumeration indicating the target culture for the assembly
AssemblyDelaySign True to indicate that delayed signing is being used
AssemblyDescription Short description of the assembly
AssemblyFileVersion String specifying the Win32 file version. Defaults to the AssemblyVersion value.
AssemblyInformationalVersion Human-readable version; not used by the common language runtime
AssemblyKeyFile Name of the file containing keys for signing the assembly
AssemblyKeyName Key container containing a key pair to use for signing
AssemblyProduct Product Name
AssemblyTitle Friendly name for the assembly
AssemblyTrademark Trademark information
AssemblyVersion Version number expressed as a string.

You can also define your own custom attributes by inheriting from the System.Attribute class. These attributes will be available in the assembly manifest just like the attributes listed above.

0
 
LVL 1

Author Comment

by:nzfire
ID: 17799547
Newyuppie,

Warning is GONE!! Done by commenting out the <Assembly: AssemblyFileVersion("1.0.0.*")>

Thanks a million. I've learnt a lot from a silly little thing like that!
0
 
LVL 13

Expert Comment

by:newyuppie
ID: 17799574
glad it worked out! i learn a lot too from researching for little things too!
thanks for the grade

NY
0

Featured Post

Become an Android App Developer

Ready to kick start your career in 2018? Learn how to build an Android app in January’s Course of the Month and open the door to new opportunities.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

621 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question