ASP高手帮我看看,谢谢

来源:百度知道 编辑:UC知道 时间:2024/05/03 06:57:22
错误 '80020009'
/xyhua158/bbs/setup.asp,行 54
用两个用户登临,一个成功,另一个出现以上的错误,两个密码相同。不知道为什么?

54行下下的内容是:
if Request.Cookies("username") <> empty then
sql="select * from [user] where username='"&HTMLEncode(Request.Cookies("username"))&"'"
Set Rs=Conn.Execute(SQL)
if rs.eof then Response.Cookies("username")=""
if Request.Cookies("userpass") <> rs("userpass") then Response.Cookies("username")=""
//上面两行就是第54行
membercode=rs("membercode")
userface=""&rs("userface")&""
newmessage=rs("newmessage")
userlife=rs("userlife")
set rs=nothing
end if

f Request.Cookies("username") <> empty then
sql="select * from [user] where username='"&HTMLEncode(Request.Cookies("username"))&"'"
Set Rs=Conn.Execute(SQL)
if rs.eof then
Response.Cookies("username")=""
else
if Request.Cookies("userpass") <> rs("userpass") then Response.Cookies("username")=""
'//上面两行就是第54行
membercode=rs("membercode")
userface=""&rs("userface")&""
newmessage=rs("newmessage")
userlife=rs("userlife")
end if
set rs=nothing
end if

end if 少了一个
并且if Request.Cookies("userpass") <> rs("userpass") then Response.Cookies("username")=""
执行的前提应该not rs.eof 你没有判断