You didn't post your code, but what the error is saying is that you are trying to assign a NULL to a number type field which cannot hold a NULL. Only a Variant type or a String type can be NULL.
One way is to set the number type field to EMPTY.
("AccidenteID_FK" is a Long Integer)
Code:
Public Sub SetNumberToEmpty()
Dim d As DAO.Database
Dim r As DAO.Recordset
Dim sSQL As String
'open a record set
sSQL = "SELECT tblVehicles.AccidenteID_FK"
sSQL = sSQL & " FROM tblVehicles"
sSQL = sSQL & " WHERE tblVehicles.VehicleID_PK = 1;"
Set d = CurrentDb
Set r = d.OpenRecordset(sSQL)
If Not r.BOF And Not r.EOF Then '<<-- test for records
r.Edit
r("AccidenteID_FK") = Empty '<<--set field to empty
r.Update
End If
'clean up
r.Close
Set r = Nothing
Set d = Nothing
End Sub