Sandra Smith
asked on
Unlock controls based on user type when form opens
I have an Access 2003 form that records updates and also allows entry of time, but time entry is only availabe is the person's work type is 'DEV'. I have a procedure that checks the perons's type and if it is DEV, then when the form Opens, I want the time controls unlocked. but it seesm I have a problem in that the code does not run (i get null values) so I think it is a resolutionissue as to which event should I put the procedure to run to unlock when teh form opens?
ASKER
The time control are where the developers enter the project they are working on and the amount of time they spent on it. I would ideally like these text boxes available for data entry when the form opens, checks the user id and determines that it is a develoer, otherwise, these fields should remain disabled.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Should this be a function that returns a value to a global variable?
post the Procedure that you are talking about ..
where is this pocedure, in a regular module ?
where is this pocedure, in a regular module ?
ASKER
Actually, this gave me an idea that satisifed what I needed. I assigned the global value on the calling form, which set the value I needed on the called form and it is happy little form now. Does exactly what I want.
Sandra
Sandra
what time controls are talking about ?
are these textboxes from the form ?
<I have a procedure that checks the perons's type and if it is DEV>
how do you apply the result to you unlocked the time controls ?