有关ASP数据库连接的问题,高人们看看把
错误类型: Microsoft OLE DB Provider for ODBC Drivers (0x80040E4D) /llgs/selec.asp, 第 19 行 代码:<html> <head>
<title>登陆</title> </head>
<body> <div align=center>
<table border=1 cellSpacing=0 width="46%"> <tr><td>企业注册号</td><td>企业类别</td><td>企业所属地</td><td>企业名称</td><td>企业地址</td></tr> </table>
<% dim rs,sql dim conn
set conn=server.createobject("ADODB.Connection") conn.open"Driver={SQL Server};" &"Server=WY1;"_ &"Database=LearnAsp;"_ &"Uid=sa;"_ &"Pws=8221385" set rs=server.createobject("ADODB.Recordset")
sql="select * from DataSlece"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<tr bgcolor='#E6E6E6'align='center'>" response.write"<td>"& rs("ENROL_NO")& "</td>" response.write"<td>"& rs("CALLING")& "</td>" response.write"<td>"& rs("ADD")& "</td>" response.write"<td>"& rs("ENROL_NAME")& "</td>" response.write"<td>"& rs("ADD_EMBODY")& "</td>" response.write"</tr>" rs.MoveNext loop response.write "</table>" set rs=nothing conn.close set conn=nothing %> </div> </body> </html>