Could anyone help me please...
When I try and archive, I get this error:
quote:
....................................................................................................
....................................................................................................
....................................................................................................
....................................................................................................
....................................................................................................
....................................................................................................
....................................................................................................
....................................................................................................
....................................................................................................
....................................................................................................
....................................................................................................
....................................................................................................
...............................................
All replies to Topics older than 12/01/2004 23:06:41 were archived
Microsoft JET Database Engine error '80040e07'
Data type mismatch in criteria expression.
/forum/admin_forums.asp, line 585
Line 585 is the one in red:
if rsTcheck.eof then
err.clear
strsqlvalues = "" & drs("CAT_ID") & ", " & drs("FORUM_ID") & ", " & drs("TOPIC_ID") & ", " & 0
strsqlvalues = strsqlvalues & ", '" & chkstring(drs("T_SUBJECT"),"archive") & "', '" & chkstring(drs("T_MESSAGE"),"archive")
strsqlvalues = strsqlvalues & "', " & drs("T_AUTHOR") & ", " & drs("T_REPLIES") & ", " & intT_UREPLIES & ", " & drs("T_VIEW_COUNT")
strsqlvalues = strsqlvalues & ", '" & drs("T_LAST_POST") & "', '" & drs("T_DATE") & "', " & drs("T_LAST_POSTER")
strsqlvalues = strsqlvalues & ", '" & drs("T_IP") & "', " & drs("T_LAST_POST_AUTHOR") & ", " & intT_LAST_POST_REPLY_ID & ", '" & drs("T_LAST_EDIT")
'####################### Poll Mod - Modified next line ########################
strsqlvalues = strsqlvalues & "', " & intT_LAST_EDITBY & ", " & drs("T_STICKY") & ", " & drs("T_ISPOLL") & ", " & 0 & ", " & drs("T_SIG") & ", "& drs("T_POSTS") &" "
'##############################################################################
strsqlvalues = strsqlvalues & ", '" & drs("T_EVENT_DATE") & "', " & drs("T_ISEVENT") & " "
'###################### Poll Mod - Added T_ISPOLL and T_POLLSTATUS to next line ##############
strsql = "INSERT INTO " & strArchiveTablePrefix & "TOPICS (CAT_ID, FORUM_ID, TOPIC_ID, T_STATUS, T_SUBJECT, T_MESSAGE, T_AUTHOR, T_REPLIES, T_UREPLIES, T_VIEW_COUNT, T_LAST_POST, T_DATE, T_LAST_POSTER, T_IP, T_LAST_POST_AUTHOR, T_LAST_POST_REPLY_ID, T_LAST_EDIT, T_LAST_EDITBY, T_STICKY, T_ISPOLL, T_POLLSTATUS, T_SIG, T_EVENT_DATE, T_ISEVENT, T_POSTS)"
'#############################################################################################
strsql = strsql & " VALUES (" & strsqlvalues & ")"
'Response.Write strSql
'Response.End
my_conn.execute(strsql),,adCmdText + adExecuteNoRecords
msg = " <center><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """ color=""" & strForumFontColor & """>All topics older than " & strToDate(fdateolderthan) & " were archived</font></center><br />" & vbNewLine
else
Anyone have any ideas please?