Visual Basic Code , VB.NET Code, VB Code
  Home   :  Code   :  Forums   :  Submit   :  Mailing List   :  About   :  Contact
A1VBCode Forums
Home      Members   Calendar   Who's On
Welcome Guest ( Login | Register )
      

Home » .NET Programming » Visual Basic .NET/2005/2008 » How to retrieve the Version no of Application...


How to retrieve the Version no of Application...Expand / Collapse
Author
Message
Posted 8/27/2008 9:23:27 AM
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Forum Members
Last Login: 9/5/2008 1:08:19 AM
Posts: 11, Visits: 50
Hi,

How to retreive the version no application reunning in the system.I have to get all the processes from the registry.

Post #25622
Posted 8/29/2008 8:54:36 AM


Forum God

Forum GodForum GodForum GodForum GodForum GodForum GodForum GodForum God

Group: Forum Members
Last Login: Today @ 3:25:33 AM
Posts: 846, Visits: 5,126
To get the version no. in vb 2005 or vb 2008 use :

MessageBox.Show(My.Application.Info.Version.ToString)



Wayne

I know enough to be dangerious.

It is hard to understand how a cemetery can raise its burial rates and blame it on the cost of living.

Post #25626
Posted 8/29/2008 3:04:36 PM


Forum God

Forum GodForum GodForum GodForum GodForum GodForum GodForum GodForum God

Group: Forum Members
Last Login: Today @ 7:34:31 PM
Posts: 1,465, Visits: 3,404
coolest_avi007 (8/27/2008)
Hi,

How to retreive the version no application reunning in the system.I have to get all the processes from the registry.

Now I know this is mainly for VB6 but there is some VB.Net examples in there. Download and install API-Guide.

 

'VB6 GetFileVersionInfoSize API

'The GetFileVersionInfoSize function determines whether the operating system can obtain
'version information about a specified file. If version information is available,
'GetFileVersionInfoSize returns the size in bytes of that information.

'VB.Net code

Imports System
Imports System.Diagnostics
Public Module modmain

Sub Main()
'The KPD-Team 2001
'URL: http://www.allapi.net/dotnet/
'E-Mail: KPDTeam@Allapi.net
Dim versionInfo As FileVersionInfo = FileVersionInfo.GetVersionInfo("C:\Windows\Notepad.exe")
Console.WriteLine("Notepad version " + versionInfo.FileVersion)
Console.WriteLine("Description: " + versionInfo.FileDescription)

End Sub
End Module




Keith

http://www.martin2k.co.uk/forums/

I've been programming with VB for 12 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.
Post #25627
Posted 9/4/2008 4:44:44 AM
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Forum Members
Last Login: 9/5/2008 1:08:19 AM
Posts: 11, Visits: 50
thnx for the reply..

but whatever you have mentioned above is only for a particular application.

But I need to get information about all the application running in the system?

do i need to get the info from the registry of the windows?

Post #25644
Posted 9/6/2008 6:23:07 AM


Forum God

Forum GodForum GodForum GodForum GodForum GodForum GodForum GodForum God

Group: Forum Members
Last Login: Today @ 3:25:33 AM
Posts: 846, Visits: 5,126
I'm afraid you will have to go to registery. However, I do not know how to find anything there. If you knew where the exe was stored you could get the version number from the header.

Wayne

I know enough to be dangerious.

It is hard to understand how a cemetery can raise its burial rates and blame it on the cost of living.

Post #25657
« Prev Topic | Next Topic »


Reading This TopicExpand / Collapse
Active Users: 1 (1 guest, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: Brian, Peter

PermissionsExpand / Collapse

All times are GMT -5:00, Time now is 11:12pm