Function used in Combo box record source not working (1 Viewer)

robert693

Registered User.
Local time
Today, 06:49
Joined
Mar 22, 2001
Messages
38
Hello,

I have a database that is used by the managers of several departments of a company. The database stores information about the performance of the employees in each department. I have a query that computes averages from information about each employee entered by each manager. The managers enter the data into a form with a query called qryComputeAppraisal as its record source. To keep data integrity, I have a table called Employees with the employee names. A combo box in the form uses this table as its record source. The employee name when entered is then put into the employee in qryComputeAppraisal. I want the managers to see only the employees within their department. I found a function that pulls in the login ID of whoever is logged at the time. I use this login ID in the record source of the combo box to show only those emplloyees that are in the manager's department. This works fine when the manager is entering data. Whe a manager uses Find to find a record however, he or she is still able to pull up any record, including those from other departments. Is there a way to hide all employees from outside the department of the manager currently logged in? Am I going about this the right way? Any help is greatly appreciated!
 

Users who are viewing this thread

Top Bottom