I have an form that takes in some information, and then calls confirm.asp to insert the record into my database.
I get this error:
Error Type:
ADODB.Recordset (0x800A0BB9)
Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.
/confirm.asp, line 10
Here is my confirm.asp
Code:
<%
dim objConn
Set objConn=Server.CreateObject("ADODB.Connection")
objConn.ConnectionString="Provider=Microsoft.Jet.OLEDB.4.0;Data Source="&Server.MapPath("db\testdb.mdb")&";"
objConn.Open
dim objRS
Set objRS=Server.CreateObject("ADODB.Recordset")
objRS.Open "tblContact",objConn,,adLockOptimistic,adCmdTable
objRS.AddNew
objRS("Email")=Request.Form("Email")
objRS("FirstName")=Request.Form("FirstName")
objRS("LastName")=Request.Form("LastName")
objRS("Comments")=Request.Form("Comments")
objRS("DateContacted")=Date()
objRS.Update
%>
<p>
<%
dim strFirstName
strFirstName = Request.Form("FirstName")
%>
<br>
</p>
<%
objRS.Close
set objRS=Nothing
objConn.Close
set objConn=Nothing
%>
Thanks.