这样的语句为何提示错误?请大虾帮忙!
<% set conn=server.createobject("adodb.connection")
conn.open "driver={microsoft access driver (*.mdb)};dbq="&server.mappath("sj1.mdb")
set rs=server.CreateObject("adodb.recordset")
sqlstr="select * from test"
rs.open sqlstr,conn,1,3
if rs.eof then
rs.addnew
rs("name").value=name
rs("sex").value=sex
rs("age").value=age
rs.update
rs("note").value=note
rs.close
conn.close
set rs=nothing
set conn=nothing
end if
set conn=nothing
response.write "记录添加成功!"
rs.close
set rs=nothing
conn.close
set conn=nothing
%>
错误代码
技术信息(用于支持人员)
- 错误类型:
Microsoft VBScript 运行时错误 (0x800A01A8)
缺少对象
/reg.asp, 第 32 行
- 浏览器类型:
Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; InfoPath.1) - 网页:
POST 38 ??? /reg.asp - POST Data:
name=&age=24¬e=&Submit=%CC%E1%BD%BB