Results 1 to 3 of 3
  1. #1
    Mister-B is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jan 2018
    Posts
    31

    FindFirst with two conditions

    Hi there,



    I'm trying to use rs.findfirst to find the first record that meets two conditions:

    rs.FindFirst "Buchnummer ='" & Me.txtBuchnummer & "'" And "Ehemalig ='" & "False"""

    However I try, I just can't get the synthax right. Can anybody help, please?

    Regards,
    Martin

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,926
    The AND is literal text and must be within quote marks. Also, if Ehemaliq is yes/no field, don't use apostrophe delimiters. False is an intrinsic constant and holds a value of 0.

    rs.FindFirst "Buchnummer='" & Me.txtBuchnummer & "' And Ehemalig=False"
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    Mister-B is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jan 2018
    Posts
    31
    Thank you very much. That works great

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

Similar Threads

  1. DAO Recordset FindFirst
    By GraeagleBill in forum Programming
    Replies: 4
    Last Post: 05-25-2019, 11:12 AM
  2. FindFirst error
    By Bazsl in forum Programming
    Replies: 6
    Last Post: 03-01-2017, 09:21 AM
  3. Recordset FindFirst
    By Praveenevg in forum Access
    Replies: 1
    Last Post: 08-18-2014, 12:55 PM
  4. .FindFirst problem
    By akhmadahdiyat in forum Programming
    Replies: 2
    Last Post: 11-29-2013, 12:27 AM
  5. Using FindFirst code
    By saltydawg617 in forum Access
    Replies: 2
    Last Post: 07-29-2011, 05:21 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