<% Option Explicit %> <% Dim objConn Set objConn = Server.CreateObject("ADODB.Connection") objConn.ConnectionString = "DSN=pubs;UID=sa;PWD=;" objConn.Open 'Must use the master database, where xp_regread exists... objConn.Execute "USE MASTER" Dim strSQL strSQL = "xp_regread 'HKEY_LOCAL_MACHINE', 'SOFTWARE\Microsoft\MSSQLServer\Setup','SQLPath'" Dim objRS Set objRS = objConn.Execute(strSQL) Response.Write "SQL Server installed at " & objRS("Data") objRS.Close Set objRS = Nothing objConn.Close Set objConn = Nothing %>