Multiple-step OLE DB operation generated errors 
Author Message
 Multiple-step OLE DB operation generated errors

Hi!  I have the following simple code (I included the whole thing) that will
add a user's name and e-mail to an Access 2000 database.

' Create the objects
Dim oConn, oRs
Set oConn = Server.CreateObject("ADODB.Connection")
Set oRs = Server.CreateObject("ADODB.Recordset")

' Open the connection and database
oConn.Open "Driver=Microsoft Access Driver (*.mdb);DBQ=" &
Server.MapPath("data/Newsletter.mdb")
oRs.Open "[General]", oConn, 1, 3, 2

' Add a new record
oRs.AddNew

' Add values to the fields
oRs("Email") = LCase(Trim(Request.Form("Email")))
oRs("Name") = Trim(Request.Form("Name"))

' Update the database
oRs.Update

' Close the database
oRs.Close
oConn.Close
Set oRs = Nothing
Set oConn = Nothing

' Save the user's name in a cookie so it can be referenced by other pages
Response.Cookies("WebDream")("Name") = Trim(Request.Form("Name"))

' Redirect the user to the home page
Response.Redirect("default.asp")
Response.End

I get this error when I execute the code:
Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E21)
Multiple-step OLE DB operation generated errors. Check each OLE DB status
value, if available. No work was done.

Please help me!
AP

PS - You can even use the code if you want.



Sun, 03 Oct 2004 03:52:20 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Error: Multiple step OLE DB operation generated errors

2. Error: Multiple-step OLE DB operation generated errors

3. Multiple-step OLE DB operation generated errors....

4. Multiple-step OLE DB operation generated errors

5. Multiple-step OLE DB operation generated errors.

6. Multiple-step OLE DB operation generated errors

7. Multiple-step OLE DB operation generated errors.

8. Multiple step OLE DB operation generated errors

9. Multiple-step OLE DB operation generated errors

10. FileSystemObject.FileCopy Multiple-step OLE DB operation generated errors

11. Multiple-step OLE DB Operation Generated Errors

12. Multiple-step OLE DB Operation Error

 

 
Powered by phpBB® Forum Software