How to determine whether a VS 2008 product is installed on a computer

I previously posted a list of registry values that can be used to detect Visual Studio 2005 editions.  I've started getting asked more often about how to detect Visual Studio 2008, so I decided to create a separate post with an equivalent list of registry values for the VS 2008 product family too.

Here is a list of the registry keys/values that can be used to detect each of the editions of Visual Studio 2008.  In each case below, ProductDir is a REG_SZ value that contains the install root (which by default will be c:\Program Files\Microsoft Visual Studio 9.0).

  • Visual Basic 2008 Express - HKEY_LOCAL_MACHINE\Software\Microsoft\VBExpress\9.0\Setup\VS\ProductDir
  • Visual C++ 2008 Express - HKEY_LOCAL_MACHINE\Software\Microsoft\VCExpress\9.0\Setup\VS\ProductDir
  • Visual C# 2008 Express - HKEY_LOCAL_MACHINE\Software\Microsoft\VCSExpress\9.0\Setup\VS\ProductDir
  • Visual WebDev 2008 Express - HKEY_LOCAL_MACHINE\Software\Microsoft\VWDExpress\9.0\Setup\VS\ProductDir
  • Visual Studio 2008 Standard - HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\9.0\Setup\VS\Std\ProductDir
  • Visual Studio 2008 Professional - HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\9.0\Setup\VS\Pro\ProductDir
  • Visual Studio Team System 2008 Architecture Edition - HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\9.0\Setup\VS\VSTA\ProductDir
  • Visual Studio Team System 2008 Test Edition - HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\9.0\Setup\VS\VSTT\ProductDir
  • Visual Studio Team System 2008 Development Edition - HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\9.0\Setup\VS\VSTD\ProductDir
  • Visual Studio Team System 2008 Team Suite - HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\9.0\Setup\VS\VSTS\ProductDir
  • Visual Studio 2008 Shell - HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\9.0\Setup\VS\IDE\ProductDir

If you do not care which edition is installed, you can use the following registry value to detect whether or not any edition of Visual Studio 2008 is installed:


9.0 is a REG_SZ value that specifies a fully qualified path to the Visual Studio 2008 root installation directory.  By default, this value will be set to c:\Program Files\Microsoft Visual Studio 9.0, but will be different if the user has installed Visual Studio 2008 to a non-default path.

Comments (5)

  1. Massimiliano Polito says:

    What about writing a script I can deploy on 30 machines and see what version/edition of Visual Studio is installed at each workstation?

    If you feel like doing it, you can email it at massimiliano.polito at gmail . com, I'll be glad to test it 🙂

  2. Hi Massimiliano Polito – I'm sorry, but I don't have the time to create this type of script right now.  It should be pretty straightforward for you to create something like this using the information in this blog post though.  Please let me know if you run into any issues with any of the detection logic described in this post.

Skip to main content