How to get File Version of App from within the App... C#

XML, Perl, Python, and other languages can be discussed here, even if it isn't PHP (We might forgive you).

Moderator: General Moderators

Post Reply
User avatar
daedalus__
DevNet Resident
Posts: 1925
Joined: Thu Feb 09, 2006 4:52 pm

How to get File Version of App from within the App... C#

Post by daedalus__ »

I'm trying to make a small about box for my application. I want to take the version number that is kept in the assemblyinfo.cs file, that way i can just update that number every important build and not have to change the about box.

i have no idea how to do this. reflection?
timvw
DevNet Master
Posts: 4897
Joined: Mon Jan 19, 2004 11:11 pm
Location: Leuven, Belgium

Post by timvw »

User avatar
daedalus__
DevNet Resident
Posts: 1925
Joined: Thu Feb 09, 2006 4:52 pm

Post by daedalus__ »

This was sooooooo much easier than people made it out to be that I am lol'ing. I spent three hours just trying to do this.

code:

Code: Select all

System.Reflection.Assembly.GetExecutingAssembly.GetName.Version.ToString();
You should have seen some of the crap people used to do this.[/syntax]
Post Reply