Question User Log In

dichotomous

Registered User.
Local time
Today, 14:11
Joined
Oct 19, 2012
Messages
62
I have a database that I have developed for the management of health and safety on an industrial site.

It is split. I have developed a log in screen to keep unwanted people out.

There is also a reminder's table that serves three tables - Contractors, Accidents and Employees. You will see those three FK's in that table in the sample I have attached.

A sub form base on a query sits on the Contractors form, Accident Form and Employees in which you can enter a reminder. When I open the data base, I have a pop up that says you have overdue tasks would you like to view.....at this stage of the game though all I can achieve is generic, i.e; not specific to a user.

What I want to achieve is, when an new entry is made in the reminder's table, the current user (who has logged in) is entered into a field.

I have tried the tempvars method, but, cannot find code to pass the temporary variable to the table.

I know that this can be done, but it is outside of my scope of skills.

I have put the relevant tables into a shell and uploaded for you to look at. The main database is way too big to load up (and privacy reasons).

user name: fnicoll
Pass 1234

will get you in.

Hoping for help and, thank you in advance.
 

Attachments

I haven't used TempVars (old dog, new trick). Simplest may be to leave the login form open but hidden instead of closing it. That will let you refer to the user textbox from anywhere.
 
Hi Paul

well, that's not a bad Idea.

How do I do that?

How do I capture the login on the log in form and use it as a value in a field when a new entry is made?????
 
Instead of closing it:

Me.Visible = False

Then you can use it anywhere, for example the default value property of a textbox:

Forms!FormName.TextboxName
 
OMG, that worked a treat.

Thank you sooo much. You have saved me hours and headaches.

:o
 
Happy to help!

You can edit the thread and change the title/prefix to Solved.
 

Users who are viewing this thread

Back
Top Bottom