Getting the BizTalk SQL Server DB Name
A quick one. How to get the name of the SQL Server that BizTalk is running? A relatively easy way is to get it from the registry. Heres a code sippet that does just that.
string strBtsSvrSubKey =
"Software\\Microsoft\\BizTalk Server\\3.0\\Administration";
string strBtsSqlSvrKey = "MgmtDBServer";
Microsoft.Win32.RegistryKey key = Microsoft.Win32.Registry.LocalMachine.OpenSubKey(strBtsSvrSubKey);
string strBtsSqlSvrName = key.GetValue(strBtsSqlSvrKey).ToString();
Any queries, post a comment.