Daniel
Daniel

Reputation: 19

Auto version in Advanced Installer using AssemblyVersion from .Net application

I'd like to synchronize version in Advanced Installer when create setup installer file using AssemblyVersion from .NET application which is set to 1.0.*. I have choosen myApp.exe in version field of Advanced Installer, but it only set two first numbers, major and minor version and get 1.0.0.0. What should I do to set full version and see two last auto generated while compiling numbers of version?

Upvotes: -1

Views: 73

Answers (1)

J.Tribbiani
J.Tribbiani

Reputation: 530

When you define an assembly version in .NET using the AssemblyVersion attribute, you might specify only the major and minor versions, omitting the build and revision numbers.

The version is generally defined in the format "major.minor.build.revision". If you specify only the major and minor parts (for example, 1.0), the build and revision numbers are indeed not specified by you directly.

However, when the assembly is compiled, these unspecified components are automatically set to zero by default.

The AssemblyVersion attribute allows you to specify version numbers for your assembly in the following format:

[assembly: AssemblyVersion("major.minor.build.revision")]

enter image description here

This is why the Advanced Installer, during the sync operation for the ProductVersion of the installer with the Assembly version, will add the build & revision numbers as "0", as they are contained by the assembly.

Upvotes: 0

Related Questions