VB.NET - Compare current application assembly version against another

fruitloopy
fruitloopy used Ask the Experts™
on
As I release updates for my application I would like it to check for an updated version in a particular directory on load. As far as I can see this needs to compare the current application assembly or file version with an updated exe in a directory.
I cannot seem to find a reasonably simple way of doing this.

I would share some code with you but I just cannot find any that seems to fit the bill.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Software Architect in .Net
Commented:
You can get the file version from any executable file. Try this:

Private Function GetFileVersionInfo(ByVal filename As String) As Version
    Return Version.Parse(FileVersionInfo.GetVersionInfo(filename).FileVersion)
End Function

Open in new window

Hope that helps.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial