I have two combo boxes named TrainingName and CustomerName. what i wanted to do is by selecting a training name and customer name i would be able to search that in my MembersTraining query and print a report. For example i selected "Ben Gonzales" in the CustomerName and "ICT 1" in TrainingName, all of the information about Ben Gonzales in the ICT 1 training will be in that report.
here's my code.
Dim stDocName As String
stDocName = "rptMemberstraining"
DoCmd.openreport stDocName, acPreview, , "[fld_CustomerNameID]=" & Me!CustomerName.Value And "[fld_TrainingName]=" & Me!TrainingName.Value
unfortunately this code isn't correct. =(
thanks.