Please note: to provide completed code or a completed project is against site policy. Please consult the FAQ and specific forum sticky threads for further information.
---><---
You are not very clear in how your application is designed.
You do not state which version of Access you are using.
There are 5 ways off the top of my head to solve this problem: which one depends on your particular situation.
I will however take a stab:
ASSUMPTION ONE:
You have a split database... to be clear: that means that there is one central data store commonaly refered to as the "back-end (BE)." The BE contains only the data, main queries and main reports AND is located on a central server share. There are numerous "front-ends (FE)" that are normally downloaded to each client PC.
ASSUMPTION TWO:
When the FE is opened on a client PC by a NON-Management user; you have a form that once opened you need to ensure that a manager has authorized the action.
EACH user has THEIR OWN copy of the FE on their PC.
ASSUMPTION THREE:
The manager will be using a seperate PC from the others.
From your post, you may User A on PC AA, User B on PC BB, and User M on PC MM.
User M is management, all others are non-management.
In your BE you will need to have a means of tracking which form of internest is open and by which user.
So when User A opens the form, this will be noted.
So when User B opens the form, this will be noted.
I would use the timer event in the form to check for approval. Once found, the close button is either enabled or made visible.
I would also use the
Form.Unload Event (Access) Office 2010 to check against the record you need to have a date recorded and against the management approval and cancel the unload if either are missing. IF the date is there; however, no management approval then I'd throw an error message at the user, the manager, and send emails out to the next level up in the management food chain, IT Security, and the DBA.
User M, logs into PC MM and opens a form that will show that A and B have pending actions. M can then select one, both, all, etc... and confirm the pending actions.
If M is to use either PC AA or BB then you will need a way to verify that it is actually M. I would use a management approval button on the form that enquires about M's user id and password/PIN - each field I'd used the password format so as to keep both somewhat protected from common knowledge; however, for security, I would use a different terminal and no management button. IN anycase, the button's code would then either send out a bunch of nasty grams to the management team if the validation failed or make your record updates and either close the form or enable the close button.
I envision at least one table that holds the tracking.
I envision at least two forms... one that is the manager's control panel and the remaining forms are the ones yo need tracked.
You might even have a "Management" FE vs POU FE: I've done this for myself. In several of the DB I have live in the labs, there is a Management FE that only supervisors and others under the ActiveDirectory Security can d/l and a POU for the labs.
Beton, if you have not done so please read thru the posting guidlines:
> Out right requests for full code are against site policy.
> Bytes is not a code nor homework service. Please read the FAQ and posting guidelines before re-posting your question.
>> Before Posting (VBA or SQL) Code.
>> How to ask "good" questions -- READ BEFORE SUBMITTING A QUESTION!.
>> POSTING_GUIDELINES: Please Read Carefully Before Posting to a Forum.