Until last week, the front and back end of the application I use were split. They are now in one file (for 'political' reasons
).
Although it worked perfectly beforehand, since the merger, the following code produces an error "Runtime Error 3021: No current record"
The only difference is that now the tables are stored in the database itself, as opposed to being linked. I don't see how that would cause a problem, but I'm open to suggestions.
![Mad :mad: :mad:](https://cdn.jsdelivr.net/joypixels/assets/8.0/png/unicode/64/1f621.png)
Although it worked perfectly beforehand, since the merger, the following code produces an error "Runtime Error 3021: No current record"
Code:
str_Account1 = UCase([Forms]![Referral to BMO]![Account #])
If Me.Dirty Then
Me.Undo
End If
Call Prevent_Referral_Entry
'Main Form
'---------
Set Rst = [Forms]![Referral to BMO].RecordsetClone
Rst.FindFirst "[Account #]= '" & [Forms]![Referral to BMO]![Account #] & "'"
'*****ERROR POINT IN DEBUG *****
[Forms]![Referral to BMO].Bookmark = Rst.Bookmark
'****************************
'Subform
'-------
str_Data = "SELECT * FROM NBReferral " & _
"WHERE [Account #]= '" & [Forms]![Referral to BMO]![Account #] & "'"
[Forms]![Referral to BMO]![Referral to BMO Search Subform].Form.RecordSource = str_Data
[Forms]![Referral to BMO]![Referral to BMO Search Subform].Form.Requery
Exit Sub