I checked for other posts and some of them said that you CAN update NULL into a date/time field of an access database via DAO... How come I get a #13 'Type mismatch'?
Please help this is anoying me alot :)
Printable View
I checked for other posts and some of them said that you CAN update NULL into a date/time field of an access database via DAO... How come I get a #13 'Type mismatch'?
Please help this is anoying me alot :)
How are you Nulling the Date Value?
The following works for me:
------------------Code:Private Sub Command1_Click()
Dim oDB As Database
Dim oRS As Recordset
Set oDB = OpenDatabase("C:\Files\DB1.mdb")
Set oRS = oDB.OpenRecordset("MyTable", dbOpenTable)
While Not oRS.EOF
oRS.Edit
oRS("DateField") = Null
oRS.Update
oRS.MoveNext
Wend
oRS.Close
oDB.Close
End Sub
Aaron Young
Analyst Programmer
[email protected]
[email protected]
Thanks Aaron...
I'm stupid... you told me once that in a IIF, vb checks both possibilities... that was in a IIF.... gess I forgot what the master said to the student :)