By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,236 Members | 1,839 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,236 IT Pros & Developers. It's quick & easy.

Retrieve program version as it is in Add/Remove Programs??

P: n/a
Hi folks,

I'm searching on this issue since a couple of days:

How do I programmatically retrieve the version of an installed
program? Is there a possibility to retrieve it via the local MSI
database? Or do I have an other chance to get to this information? I
need to retrieve it because I do have to check if an update of my app
is necessary. But therefore I need to know what Version currently is
installed.

It drives me insane, because there is no chance to get this
version-info - besides checking each DLL or assembly for the version,
which is not that kind of reliable...

Does anybody have a glue? Perhaps via MSI?

TIA!
Eddy
Nov 16 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Hi Eddy,

It's in the registry - but the form is cryptic indeed. Every application and
package installed via MSI has a GUID, and you should know the GUID to
retrieve the information on an application or a package.

Check out the following keys:

HKEY_CURRENT_USER\Software\Microsoft\Installer\Pro ducts
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\Curr entVersion\Installer\UserData

--
Sincerely,
Dmitriy Lapshin [C# / .NET MVP]
Bring the power of unit testing to the VS .NET IDE today!
http://www.x-unity.net/teststudio.aspx

"Eddy Fuchs" <ed***@intec-ag.com> wrote in message
news:ba**************************@posting.google.c om...
Hi folks,

I'm searching on this issue since a couple of days:

How do I programmatically retrieve the version of an installed
program? Is there a possibility to retrieve it via the local MSI
database? Or do I have an other chance to get to this information? I
need to retrieve it because I do have to check if an update of my app
is necessary. But therefore I need to know what Version currently is
installed.

It drives me insane, because there is no chance to get this
version-info - besides checking each DLL or assembly for the version,
which is not that kind of reliable...

Does anybody have a glue? Perhaps via MSI?

TIA!
Eddy


Nov 16 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.