Form button to autofill text boxes

Fozberry

New member
Local time
Today, 17:02
Joined
Feb 5, 2013
Messages
2
Please could someone help with this problem I've had for a while

I am trying to create a button for a form which when the user completes the rest of the form, it auto populates the "completed by" text box with their name and also fills in the date in the "completed date" text box.

I am also wanting to avoid user error by implementing the below.
I have on the form a text combo box with options 1, 2 and 3. I then have a check box called 'Paid'. I want the 'amount' to auto populate if the 'Paid' check box is selected, the amount being dependant on which option has been chosen.

Thanks
 
I have a database where users are required to log in when they open it. Username is written in tbl_Log along with the time stamp. If you want to populate your textbox, you could create a query that gets the last logged user and use dlookup to populate your textbox. If it is a network database, tbl_Log must be a local (I call it tbl_Local_Log), not linked table, or you'll get the name of the user that was logged last anywhere on the network, not always the one that is on that computer
 
Thanks for the reply; it is a split database with 2 copies and 2 users, so the lookup isn't really required. I would be happy having just the one name auto populate for each split copy. My issue is more basic in that i am not sure how to set the button to put in both name and date.
To be honest I've just bypassed some very seemingly basic query/VBA and am unable to set a text box to populate on command of a button.
 
Here is the picture. For the date part: do you want to display the current date? If so, just enter "Date()" as the control source of your textbox and format it as you want. If you want to see when this user logged in, use another dlookup to display that date.

Regards, Samo
 

Attachments

  • user_on_a_form.jpg
    user_on_a_form.jpg
    64.3 KB · Views: 135

Users who are viewing this thread

Back
Top Bottom