Hello, we have an access application (quote maintenance forms and a SQL database) that we developed and have been using for approximately 9 years. At this point in time, the main/parent file has 25,781 records in it. Until recently, everything was fine. On the form we have a "goto quote" field to allow the user to position them at the quote that they wish to work with. The first time you open the form and use the "goto quote" number field, if a quote number is entered that is really a record number in the file greater than 25,600 - the findfirst displays an arbitray record that is in the group of records from 1 thru 25,600 (not quote number, but a record that is in the first 25,600 records in the file). Second and subsequent use of the "goto quote" field, using the same findfirst processing, takes you to the CORRECT, desired quote number. This is driving me crazy. Is there some limitation to the number of records that are in a recordset at one time or something. I put in a message box for the condition of nomatch, but I'm not getting a message saying it cannot find the record, it just shows the wrong record. Below is my code. Any help with this would really be appreciated. I also tried adding a whole new "goto quote" field in the form header, and that was working, but then changes that users would make to the data would SOMETIMES not be saved (similar to the other gentleman's post today in regard to findfirst).
Private Sub goto_quote_AfterUpdate()
' Find the record that matches the control.
On Error GoTo ProcError
DoCmd.DoMenuItem acFormBar, acRecordsMenu, 3, , acMenuVer70
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[quote_ID] = " & str(Me![goto_quote])
If rs.nomatch Then
MsgBox "Record Not Found"
Else
Me.Bookmark = rs.Bookmark
End If
DoCmd.DoMenuItem acFormBar, acRecordsMenu, 5, , acMenuVer70
ExitProc:
Exit Sub
ProcError:
MsgBox "Error: " & Err.Number & ". " & Err.description
Resume ExitProc
End Sub
Thanks,
Fred