|
This did the trick... it's built to look for 2007 first, then 2010... i don't care about 2007 in my work, so I can comment that stuff out and just focus on 2010.
static RegistryKey GetMOSSRegistryKey()
{
RegistryKey key =
Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Office Server\14.0");//key = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Office Server\12.0");
//if (key == null)
//key = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Office Server\14.0");
return key;
}
static RegistryKey GetWSSRegistryKey()
{
RegistryKey key =
Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\14.0");//key = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\12.0");
//if (key == null)
//key = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\14.0");
return key;
}
Dodge
|