I'm creating a form that will list all employees at a work location and three check boxes next to their name. I want to have a combobox where the user can select the assessment year and then be able to edit the three checkboxes based on that year. Here's how I'm set up now:
Code:
tblAssessments
ID - Primary key
EmpID - employee number
AssessmentYear - (e.g. 2018)
InitialExpectations - yes/no
MidTermReview - yes/no
FinalReview - yes/no
I have a datasheet with the following SQL statement in VBA (parameter is work location chosen by the user):
Code:
SELECT tblEmployee.EmpID, tblEmployee.[LastName] & "", "" & [FirstName] AS EmpName, tblAssessments.InitialExpectations, tblAssessments.MidTermReview, tblAssessments.FinalReview, tblOffices.Code, tblAssessments.AssessmentYear FROM tblOffices INNER JOIN (tblAssessments RIGHT JOIN tblEmployee ON tblAssessments.EmpID = tblEmployee.EmpID) ON tblOffices.ID = tblEmployee.Office WHERE (((tblOffices.Code) = " & strSearch & ")) ORDER BY tblEmployee.[LastName] & "", "" & [FirstName];
Currently, it lists ALL employees at the selected office and offers three checkboxes for the reviews.
I'm drawing a complete blank on how to limit this to the user selected assessment year and list all employees. If I add in the user selected assessment period to the WHERE statement, it then only selects employees that have matching data and no longer shows ALL employees. Picture attached:

Hopefully this makes sense as to what I'm trying to do. If not, please let me know if I can add more. Due to the nature of the DB, I cannot post any parts of it here.
Thanks for any help you can offer,
Scott