asp连接数据显示数据运行测试时白屏也不报错不知道哪里出了问题
<!--#include file="conn1.asp"--><%
set rs = server.createobject("adodb.recordset")
sqlstr="select title from news"
rs.open sqlstr,conn,3,1
i=0
do while not rs.eof
i=i+1
%>
<a href="#"><%=rs("title") %></a>
<%
rs.movenext
loop
rs.close
Set rs = nothing
%>
conn1代码:<%
dim conn
dim connstr
dim db
db="db111/aa.mdb"
on error resume next
connstr="DBQ="+server.mappath(""&db&"")+";DefaultDir=;DRIVER={Microsoft Access Driver (*.mdb)};"
set conn=server.createobject("ADODB.CONNECTION")
if err then
err.clear
else
conn.open connstr
end if
sub CloseConn()
conn.close
set conn=nothing
end sub
%>