I tried and did not work, I am not shure about that but this is my code, and I get that error on if I put it to a long, currency, or interger
Private Sub Create_invoices_Click(
On Error GoTo Err_Create_invoices_Clic
Dim dbsSP As Databas
Dim pts As DAO.Recordse
Dim dtDate As Dat
Set dbsSP = CurrentDb(
Set pts = dbsSP.OpenRecordset("Payments", dbOpenDynaset
'get the information that is neede
dtDate = Me![StartDate
'prodeed only if the user actually intered somthin
If dtDate <> "" The
'calls the funchion that adds the recor
addRec pts, dtDat
'shows the newly added data
With pt
Debug.Print "new record added
End Wit
Els
Debug.Print
"you must input a string for monthly payment and payment ID
End I
pts.Clos
dbsSP.Clos
Exit_Create_invoices_Click
Exit Su
Err_Create_invoices_Click
MsgBox Err.Descriptio
Resume Exit_Create_invoices_Clic
End Su
Function addRec(rstTemp As Recordset, dt As Date
With rstTem
.AddNe
!StartingDate = d
.Updat
.Bookmark = .LastModifie
End Wit
End Function