[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

John

5/3/2007 10:30:00 AM

Hi

I am picking up app version using Application.ProductVersion.ToString. The
problem is it always comes up with 1.0.0.0. Is the version not supposed to
change with successive builds?

Thanks

Regards


3 Answers

Siva M

5/3/2007 2:07:00 PM

0

It is the assembly version that will change for every build (assuming it has
been defined so). Product version will reflect what is mentioned for the
AssemblyFileVersion attribute (in AssemblyInfo.cs if you are using VS) or
from VS menu Project | <project> Properties | Application tab and Assemly
Information dialog box.

"John" wrote:

> Hi
>
> I am picking up app version using Application.ProductVersion.ToString. The
> problem is it always comes up with 1.0.0.0. Is the version not supposed to
> change with successive builds?
>
> Thanks
>
> Regards
>
>
>

Siva M

5/3/2007 2:25:00 PM

0

Forgot to add: to get the assembly version use
Assembly.GetEntryAssembly().GetName().Version.ToString().

Assuming [assembly: AssemblyVersion ("1.0.0.*")] has been added, the above
will get a different version for each build.


"Siva M" wrote:

> It is the assembly version that will change for every build (assuming it has
> been defined so). Product version will reflect what is mentioned for the
> AssemblyFileVersion attribute (in AssemblyInfo.cs if you are using VS) or
> from VS menu Project | <project> Properties | Application tab and Assemly
> Information dialog box.
>
> "John" wrote:
>
> > Hi
> >
> > I am picking up app version using Application.ProductVersion.ToString. The
> > problem is it always comes up with 1.0.0.0. Is the version not supposed to
> > change with successive builds?
> >
> > Thanks
> >
> > Regards
> >
> >
> >

John

5/3/2007 8:55:00 PM

0

Replacing

<Assembly: AssemblyVersion("1.0.0.0")>
<Assembly: AssemblyFileVersion("1.0.0.0")>

with

<Assembly: AssemblyVersion("1.0.*")>

bring the version using Application.ProductVersion.ToString

Thanks

Regards

"Siva M" <shiva_sm@online.excite.com> wrote in message
news:0B47C9D1-E537-4EAF-95A0-FBB4EFC26A0E@microsoft.com...
> Forgot to add: to get the assembly version use
> Assembly.GetEntryAssembly().GetName().Version.ToString().
>
> Assuming [assembly: AssemblyVersion ("1.0.0.*")] has been added, the above
> will get a different version for each build.
>
>
> "Siva M" wrote:
>
>> It is the assembly version that will change for every build (assuming it
>> has
>> been defined so). Product version will reflect what is mentioned for the
>> AssemblyFileVersion attribute (in AssemblyInfo.cs if you are using VS) or
>> from VS menu Project | <project> Properties | Application tab and Assemly
>> Information dialog box.
>>
>> "John" wrote:
>>
>> > Hi
>> >
>> > I am picking up app version using Application.ProductVersion.ToString.
>> > The
>> > problem is it always comes up with 1.0.0.0. Is the version not supposed
>> > to
>> > change with successive builds?
>> >
>> > Thanks
>> >
>> > Regards
>> >
>> >
>> >