One thing is that you are missing the update command. (.Update)
I changed the lines like this
rs.Fields("ReportDate") = Me.txtReportDate.Value
to
!ReportDate = Me.txtReportDat
It doesn't hurt to use ".Value", but the value property is the default property, thus unnecessary.
Code:
MsgBox "Please select at least one item from Contractor Issues"
this indicates the list box is a multi-select list box. You will have to use looping to get all selection in the list box.
Code:
Private Sub cmdAddPerfIssue_Click()
Dim db As DAO.Database
Dim rs As DAO.Recordset
Dim val As String '<<---NOTE:"val" is a reserved word
Set db = CurrentDb()
Set rs = db.OpenRecordset("tblPerfIssues")
If Me.lstContractorIssues > "" Then
MsgBox "Please select at least one item from Contractor Issues"
Me.lstContractorIssues.SetFocus
Exit Sub
Else
Me.lstContractorIssues.Selected '<<<-- what is the purpose of this line??????
End If
If Len(Me.txtContractorOnset & vbNullString) = 0 Then
MsgBox "Please enter a Contractor Issue Onset Date"
Me.txtContractorOnset.SetFocus
Exit Sub
Else
With rs '<<--!!!!
.AddNew
' **** I edited/changed thefollowing 10 lines ****
!AnalystSpec = Me.cboAnalyst
!ReportDate = Me.txtReportDat
!ContractNumber = Me.cboContractNumber.Column(0)
!Contractor = Me.txtContractor
!MATO = Me.txtMATO
!ContractorOnset = Me.txtContractorOnset
!ContractorResolved = Me.txtContractorResolved
!ContractorComments = Me.txtContractorComments
!ContractorIssues = Me.lstContractorIssues.Column(0)
!IssueKey = Me.lstContractorIssues.Column(1)
.Update '<<----Missing!!
End With '<<--!!!!
End If
Me.lstContractorIssues.Requery
Me.txtContractorOnset = Null
Me.txtContractorResolved = Null
Me.txtContractorComments = Null
Me.txtIssuekey = Null
' OTHER CODE?????
'clean up
rs.Close
Set rs = Nothing
Set db = Nothing
End Sub