M
Mikael Hellström
Hi.,
I get this error when i am trying to close my object after this operation!
What can be wrong?
Regards Mikael
Error Type:
ADODB.Recordset (0x800A0E78)
Operation is not allowed when the object is closed.
My code
<%@ Language=VBScript%>
<!-- #include file ="./connectionStr\conStr.inc" -->
<%
if isEmpty(session("medlemsNr")) then
response.redirect("./somepage.asp")
end if
Response.buffer=true
Response.ExpiresAbsolute = Now()
Response.AddHeader "Cache-Control", "private"
session("last_move")=time()
'--------------------------------------------------------------
Dim objConn ' ADO Recordset Object
Dim objRS ' ADO Connection Object
Dim strSQL
'--------------------------------------------------------------
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.ConnectionString=connectionStr
objConn.Open
'--------------------------------------------------------------
Set objRS = Server.CreateObject("ADODB.Recordset")
strSQL="delete from rosor where id=" & request.QueryString("id")
objRS.Open strSQL, objConn
objRS.Close
Set objRS = Nothing
objConn.Close
Set objConn = Nothing
str="./rosor.asp?medlemsNr=" & request.QueryString("medlemsNr")
response.Redirect(str)
%>
I get this error when i am trying to close my object after this operation!
What can be wrong?
Regards Mikael
Error Type:
ADODB.Recordset (0x800A0E78)
Operation is not allowed when the object is closed.
My code
<%@ Language=VBScript%>
<!-- #include file ="./connectionStr\conStr.inc" -->
<%
if isEmpty(session("medlemsNr")) then
response.redirect("./somepage.asp")
end if
Response.buffer=true
Response.ExpiresAbsolute = Now()
Response.AddHeader "Cache-Control", "private"
session("last_move")=time()
'--------------------------------------------------------------
Dim objConn ' ADO Recordset Object
Dim objRS ' ADO Connection Object
Dim strSQL
'--------------------------------------------------------------
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.ConnectionString=connectionStr
objConn.Open
'--------------------------------------------------------------
Set objRS = Server.CreateObject("ADODB.Recordset")
strSQL="delete from rosor where id=" & request.QueryString("id")
objRS.Open strSQL, objConn
objRS.Close
Set objRS = Nothing
objConn.Close
Set objConn = Nothing
str="./rosor.asp?medlemsNr=" & request.QueryString("medlemsNr")
response.Redirect(str)
%>