I have an Access 200 database with a field set up as Date/Time and it is not required. When I go to insert something into the table, if there is not a date in that field, it gives me the error:
Microsoft JET Database Engine error '80040e07'
Data type mismatch in criteria expression.
Here is the page code that inserts this info:
<%
'Set the response buffer to true as we maybe redirecting
Response.Buffer = True
Dim strNotes
strNotes = Replace(Request.Form("Notes"), "'", "''")
If Trim(Request.Form("MembershipDate")) = "" Then
strMembershipDate = "ommitted"
End If
If Trim(Request.Form("LastDateOfContact")) <> "" Then
strDateLastTalked = Replace(Request.Form("LastDateOfContact"), "'", "''")
strDateLastTalked = CDate(strDateLastTalked)
End If
If Trim(Request.Form("time_talents")) <> "" Then
strTalent = Replace(Request.Form("time_talent"), "'", "''")
End If
Set conn = server.createobject("adodb.connection")
DSNtemp="Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.MapPath("new_members.mdb")
conn.Open DSNtemp
Bookmarks