I have 3 asp pages like:
ASPpage1.asp:
<% dbf_qry = "select * from mytable"
Set db_rs = CreateObject("ADODB.Recordset")
db_rs.open dbf_qry, "DSN=mydsn;UID=myid;PWD="
%>
'
' Display contents of table
'
<% db_rs.Close %>
'A button is clicked and the page is redirected to ASPpage2.asp - a
'page for data entry
ASPpage2.asp:
'Contains a submit button and html textboxes, when submit button is
'clicked results are passed on to ASPpage3 for processing
ASPpage3.asp:
<% myvar1 = Request.Form("textboxvar")
myvar2=99.99
new_qry = "Insert into cmts_unit_invty values(" & "'" & myvar1 & _
"'," & myvar2 & ")"
set new_rs = server.CreateObject("ADODB.Recordset")
new_rs.Open new_qry,"DSN=mydsn;UID=myid;PWD="
new_rs.Close
Response.Redirect("ASPpage1.asp")
%>
I get the error message:
The operation requested by the application is not allowed if the object is closed.
Why is this and how can i solve this problem? Thanks for any solutions/suggestions.
Carlos
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only