title: How to check for installed browsers using C# for newbies
body: <p>I am building an app and its a simple one, all I want it to do is display os information in plain english and the architecture as well as check for installed browsers and then I'll add the ability for it to delete cookies and what not.</p>
  
  <p>What Im stuck on is the browser detection part. Can anyone point me to some decent tutorials or how tos? Thanks.</p>
  
  <p><em><strong>Edit:</em></strong> OK I managed to finally scratch out some working code using the snippet provided by hcb below and the comments from the others (thanks everyone). So far it is doing exactly what I want so I thought id share what I have for those trying to do the same thing:</p>
  
  <pre><code>RegistryKey browserKeys;
  
          browserKeys = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\WOW6432Node\Clients\StartMenuInternet");
  
          if (browserKeys == null)
          {
              browserKeys = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Clients\StartMenuInternet");
          }
  
          string[] browserNames = browserKeys.GetSubKeyNames();
  
          foreach (string browser in browserNames)
          {
              using (RegistryKey tempKey = browserKeys.OpenSubKey(browser))
              {
                  foreach (string keyName in tempKey.GetValueNames())
                  {
                      if (tempKey.GetValue(keyName).ToString() == "Internet Explorer")
                      {
                          internetExplorerButton.Enabled = true;
                          internetExplorerButton.BackgroundImage = Properties.Resources.iExplorer;
  
                          if (internetExplorerButton.Enabled == true)
                          {
                              Label ieLabel = new Label();
                              ieLabel.Text = "Found!";
                              explorerLable.Text = ieLabel.Text;
                          }
                      }
  </code></pre>
  
  <p>To my extreme annoyance, I noticed that Google want to install their browser in the Local App Data. I managed to work this out writing the code again separately and checking:</p>
  
  <pre><code>Registry.CurrentUser.OpenSubKey(@"SOFTWARE\Google\Update\Clients");
  </code></pre>
  
  <p><em><strong>Edit2:</em></strong> Checking <code>CurrentUser</code> for Chrome seems to work fine for a few friends so it must be OK.</p>