G
Guest
I have the following insert query that gives me a type conversion error when
I try to run it. I have tried CDate() and FormatDateTime() in different
combinations but none work. The BirthDate field is a SQL smalldatetime
datatype in a table linked to the Access database I am running this in. This
is in a vb module. Any ideas would be greatly appriciated.
sqlString = "INSERT INTO guest_MET_Consumer (BirthDate) VALUES ("
sqlString = sqlString + FormatDateTime(Me.BirthDate.Value, vbShortDate) + ")"
DoCmd.RunSQL sqlString
I try to run it. I have tried CDate() and FormatDateTime() in different
combinations but none work. The BirthDate field is a SQL smalldatetime
datatype in a table linked to the Access database I am running this in. This
is in a vb module. Any ideas would be greatly appriciated.
sqlString = "INSERT INTO guest_MET_Consumer (BirthDate) VALUES ("
sqlString = sqlString + FormatDateTime(Me.BirthDate.Value, vbShortDate) + ")"
DoCmd.RunSQL sqlString