這應該不算錯誤。或者可以這樣試試:
<HTML>
<TITLE> Test</Test>
<Body>
<%
set conn=Server.CreateObject("ADODB.Connection")
conn.errors.clear
Conn.Open "Provider=SQLOLEDB;Uid=youruser;PWD=password;Initial catalog=test; Data Source=192.168.0.1"
if conn.errors.count>0 then
response.write conn.errors(0).description
end if
conn.close
set conn=nothing
%>
</Body>
</HTML>
<HTML>
<TITLE> Test</Test>
<Body>
<%
set conn=Server.CreateObject("ADODB.Connection")
conn.errors.clear
Conn.Open "Provider=SQLOLEDB;Uid=youruser;PWD=password;Initial catalog=test; Data Source=192.168.0.1"
if conn.errors.count>0 then
response.write conn.errors(0).description
end if
conn.close
set conn=nothing
%>
</Body>
</HTML>
你最好用建立的连接执行一条sql语句,看是否正常,如果没有问题,那个提示就不用理会。