Hello,
I am getting an error message when I click on "Add Record" button. I am trying to add data that was entered in a form into a table.
Getting an error message with the code below. The error I am getting is "Number of query values and destination fields are not the same".
What am I doing wrong?
I am getting an error message when I click on "Add Record" button. I am trying to add data that was entered in a form into a table.
Getting an error message with the code below. The error I am getting is "Number of query values and destination fields are not the same".
What am I doing wrong?
Code:
Private Sub AddRecord_Click()
CurrentDb.Execute "INSERT INTO MasterThroughput( [SID, Date, Case #, Entity Count, Referenced Entity #, Regional Assist?, Vendor Assist?, Fully Referenced?, LOB, Comments] )" & _
" VALUES (" & Me.SID & ", " & Me.Date & ", " & Me.Case & ", " & Me.EntityCount & ", " & Me.ReferencedEntity & ", " & Me.RegionalAssist & ", " & Me.VendorAssist & ", " & Me.FullyReferenced & ", " & Me.LOB & ", " & Me.Comments & ")"
End Sub