Accessing ProductBuild at runtime

T

Tim

I would like to display version and build in the Help>About menu for my
users during the beta-testing phase. When VisualStudio publishes the
application, it knows this information, even though I have not updated
the AssemblyInfo file; it still reads

<Assembly: AssemblyVersion("1.0,0,0")>

What object is the Publish wizard accessing to get this info?

Thanks
Tim
 
T

Tom Shelton

I would like to display version and build in the Help>About menu for my
users during the beta-testing phase. When VisualStudio publishes the
application, it knows this information, even though I have not updated
the AssemblyInfo file; it still reads

<Assembly: AssemblyVersion("1.0,0,0")>

What object is the Publish wizard accessing to get this info?

Thanks
Tim

In your main executable you can do something like:

Dim v As Version = Assembly.GetExecutingAssembly().GetName().Version

HTH,
 
T

Tom Shelton

I would like to display version and build in the Help>About menu for my
users during the beta-testing phase. When VisualStudio publishes the
application, it knows this information, even though I have not updated
the AssemblyInfo file; it still reads

<Assembly: AssemblyVersion("1.0,0,0")>

What object is the Publish wizard accessing to get this info?

Thanks
Tim

Oh... I should also mention the whole My thing. You can also use:

My.Application.Info.Version
 

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