Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / VB.NET / October 2004

Tip: Looking for answers? Try searching our database.

Installer and versioning

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Matthew - 31 Oct 2004 20:09 GMT
I found a piece of code that I can use to control the version of my
software:
<Assembly: Reflection.AssemblyVersion("1.0")>
I put this at the top of my Form1.vb file.

The question is, this version number does not replicate to my Setup Project
version.

Can this be done?

Matthew
Herfried K. Wagner [MVP] - 31 Oct 2004 20:18 GMT
"Matthew" <turn.deletethis@alltel.net> schrieb:
>I found a piece of code that I can use to control the version of my
>software:
> <Assembly: Reflection.AssemblyVersion("1.0")>
> I put this at the top of my Form1.vb file.

Did you already take a look at your project's "AssemblyInfo.vb" file?  This
file will include this attribute too.

Signature

Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/

Jay B. Harlow [MVP - Outlook] - 31 Oct 2004 20:56 GMT
Matthew,
As Herfried stated, the AssemblyVersion is normally in the AssemblyInfo.vb
file, I normally leave it as "1.0.*", then add a
AssemblyInformationalVersion attribute to AssemblyInfo.vb that I manually
keep in sync with the Setup Project.

These are the entries I normally have in my AssemblyInfo.vb files (each
project):

   <Assembly: AssemblyTitle("The VS.NET Project Title for this Assembly")>
   <Assembly: AssemblyDescription("The Description of this Assembly")>
   <Assembly: AssemblyCompany("The Company")>
   <Assembly: AssemblyProduct("The VS.NET Solution Title")>
   <Assembly: AssemblyCopyright("The Copyright for this Assembly")>
   <Assembly: AssemblyTrademark("")>
   <Assembly: CLSCompliant(True)>

   <Assembly: Guid("... a valid guid ...")>

   <Assembly: AssemblyVersion("1.0.*")>
   <Assembly: AssemblyInformationalVersion("1.0.0")>  ' Product Version

   #If DEBUG Then
   <Assembly: AssemblyConfiguration("Debug Build")>
   #Else
   <Assembly: AssemblyConfiguration("Release Build")>
   #End If

I keep AssemblyInformationalVersion the same for every project within a
solution. I keep Major & Minor numbers in sync between AssemblyVersion &
AssemblyInformationalVersion, while I let VS.NET maintain the Assembly's
build & revision numbers. I increment the Product Version as I see fit,
usually when I create a release.

Unfortunately the version numbers as defined by the above attributes are not
automatically carried forward to the Setup Project, you currently need to do
that manually. I have not played enough with the VS.NET automation see how
easy it would or would not be to automate keeping the
AssemblyInformationalVersion attribute with the Setup Project's Version
property...

Hope this helps
Jay

>I found a piece of code that I can use to control the version of my
>software:
[quoted text clipped - 7 lines]
>
> Matthew

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.