【求助】RS,CONN关闭
<!--#include file = "conn.asp"--><%
if session("admin")= "" Then ' 判断登录状态
response.write "<script>alert('非法登陆 ');location.href='admin_login.asp'</script>"
end If
%>
<%
If request("send")=" 修改链接" Then
Dim h_id,h_name,h_url,h_info,h_qq,rs5,mysql5
id=request("id")
h_name=request("name")
h_url=request("url")
h_info=request("info")
h_qq=request("qq")
%>
<%
'=========================================================================
' 数据库操作:将用户信息录入到数据库
set rs5 = server.createobject("adodb.recordset")
mysql5 = "update [h_friend] set name = '"&h_name&"',url = '"&h_url&"',info = '"&h_info&"',qq = '"&h_qq&"'where ID = "&id
rs5.Open mysql5,conn,1,3
response.write "<script>alert("" 链接修改成!"");location.href=""admin_friend.asp"";</script>"
rs5.close
Set rs5 = Nothing
conn.close
Set conn=nothing
End If
%>
------------------------------------------ 以上是代码---------------------------------------------
执行后提示:
ADODB.Recordset (0x800A0E78)
对象关闭时,不允许操作。
关闭RS,CONN,挪了半天也不知道方在哪里,怎么都放在最后了还是不行呢?应该怎么放? 关闭RS和CONN要放哪?