Results 1 to 3 of 3
  1. #1
    mainerain is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Sep 2018
    Location
    Maine, USA
    Posts
    146

    Run-time error 2162, Find window

    2162, a macro set to one of the current field's properties failed because of an error in a FindRecord action argument.



    Code:
    Me.DeviceSN.SetFocus
    Docmd.RunCommand acCmdFind
    Docmd.FindRecord"120613"
    Access Find popup form opens but 120613 doesn't get loaded into it because of this error.

  2. #2
    moke123's Avatar
    moke123 is offline Me.Dirty=True
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2012
    Location
    Ma.
    Posts
    1,879
    Use a filter

    Code:
    StrFilter = "DeviceSN = " & Me.DeviceSN        'If Number DataType
    'StrFilter = "DeviceSN = """ & Me.DeviceSN & """"      'If string DataType
    
    Me.Flter = strFilter
    Me.FilterOn = true
    If this helped, please click the star * at the bottom left and add to my reputation- Thanks

  3. #3
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    4,250
    Remove the second line as it is not needed.

    Cheers,
    Vlad Cucinschi
    MS Access Developer
    http://forestbyte.com/

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

Similar Threads

  1. Replies: 3
    Last Post: 05-31-2019, 01:52 PM
  2. Replies: 10
    Last Post: 02-18-2016, 09:44 PM
  3. Replies: 1
    Last Post: 04-30-2013, 05:44 PM
  4. Replies: 3
    Last Post: 03-03-2013, 12:22 PM
  5. Replies: 1
    Last Post: 12-01-2012, 12:44 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