Adding User Function to Database

M

magmike

I am working on adding a user function where users "log on" to use the
database. Each user will be assigned certain records and only the
assigned user can make changes.

My plan (and please tell me if I am going about this wrong) is to
change the Enabled and Locked properties of form fields based on the
user logged on. I at log on, I would store the id of the user into a
hidden, unbound form field and onCurrent, compare it to the user id
field of the current record. Once a user logs on, how do I pass that
information from form to form?

Thanks in advance!

magmike
 
J

Jeff Boyce

Another possibility would be to allow users to only SEE "their" records,
rather than letting them see all records but be dis-abled from changing any
that aren't theirs.

If you want to disable fields on a form based on whether your (hidden) user
is the user in a record, you can use that idea of the OnCurrent testing.

You don't have to "pass" the user id from form to form. You could create a
function that retrieves that id from the hidden form, with something like:

Forms!YourHiddenForm!YourUserIDFieldName

Good luck!

Regards

Jeff Boyce
Microsoft Office/Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top