Results 1 to 3 of 3
  1. #1
    Tenmakk is offline Advanced Beginner
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jun 2012
    Posts
    35

    Put the cursor in a textbox, then press a button and have the current time sent into that textbox

    I have a form with multiple textboxes and one button. I want the user to select a textbox, putting the cursor in it, and be able to then press the button to put the current time into that textbox. Is there a way to do this other than having many buttons assigned to each textbox?



    Thanks.

  2. #2
    ssanfu is offline Master of Nothing
    Windows XP Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    You could set the default value of the text box to Time()
    or you could use the On Enter event to add the time (using code).

    I would actually have the date and time in one control. Makes searching/filtering much easier.

  3. #3
    Tenmakk is offline Advanced Beginner
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jun 2012
    Posts
    35
    Thanks. I made it so the textbox updated "on enter". Much more efficient then clicking the textbox and the button, I think.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 6
    Last Post: 02-26-2016, 05:28 AM
  2. On Button Click, Record Date & Time to a Textbox
    By JakeMurray27 in forum Programming
    Replies: 2
    Last Post: 02-20-2016, 04:22 AM
  3. Replies: 4
    Last Post: 06-10-2015, 10:36 AM
  4. Replies: 6
    Last Post: 11-24-2014, 03:55 AM
  5. Replies: 9
    Last Post: 09-02-2014, 10:56 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums