Results 1 to 5 of 5
  1. #1
    cvansickle is offline Novice
    Windows Vista Access 2007
    Join Date
    Oct 2010
    Location
    Las Vegas, NV
    Posts
    21

    A simple "find record" request... I think

    Good Morning...

    I have a very simple form I created to allow a few of my warehouse people to clock in / out each day.

    I am still learning, so it is very basic.

    The trouble I am having.. Is when the employee clicks the "Clock In" Button I have it populate a text field (datename) with a unique text (date & name = "2/13/2019John Doe")

    Then when they click on the "Clock Out" button I want to to search records and find the unique text that is in datename field. and enter the clock out time in that same record



    I current have:

    DoCmd.FindRecord "2/13/2019John Doe", , True, , True -

    and it works perfectly. But I want it to search the text in datename? I have tried several ways to enter it. But can not get it to search for the text in the textbox?

    Hopefully that make sense?

    Any ideas??

    Thanks

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,521
    if you have a form showing all records (continuous form)
    right click on text box,
    CONTAINS,
    enter text: JOHN

    the list will filter.

  3. #3
    cvansickle is offline Novice
    Windows Vista Access 2007
    Join Date
    Oct 2010
    Location
    Las Vegas, NV
    Posts
    21
    Not sure I understand..

    when an employee hit the clock in button, it will put the unique text in datename field -

    [datename] = [Today] & [Sorter_Name]

    then when they hit the clock out button on the same form, I want it to "find the record" based on test string in datename field.

    I am able to get it to work if I use the text in datename field.

    DoCmd.FindRecord "2/13/2019John Brown", , True, , True. But I am not sure how to get it to look at the text string in the text field.

    I have tried things like - DoCmd.FindRecord [datename], , True, , True OR DoCmd.FindRecord me.datename, , True, , True

    However, those do not work
    Last edited by cvansickle; 02-13-2019 at 08:43 AM. Reason: add

  4. #4
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    4,101
    What happens if you try DoCmd.FindRecord Me.datename?

    Cheers,
    Vlad

  5. #5
    cvansickle is offline Novice
    Windows Vista Access 2007
    Join Date
    Oct 2010
    Location
    Las Vegas, NV
    Posts
    21
    Thanks for everyones help!!

    I think I figured out where I was going wrong.


    when I hit "Clock Out" button, I was starting with a new record, so my field was null.

    I added a line before the findrecord

    [Name2] = Date & Forms!TimeClock!Combo23.Column(1)
    DoCmd.FindRecord Me.Name2, , True, , True

    Then the name2 field had the data I was looking for.. And WAA LAAAA



    Thanks again for the time and the help!!

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

Similar Threads

  1. Replies: 7
    Last Post: 07-24-2016, 02:03 PM
  2. Replies: 3
    Last Post: 07-07-2016, 12:22 PM
  3. Replies: 11
    Last Post: 02-22-2015, 01:25 PM
  4. Replies: 5
    Last Post: 11-19-2014, 08:47 AM
  5. Replies: 3
    Last Post: 02-23-2010, 06:32 PM

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