D
Duane
Hello,
I have created my own set of navigation buttons but I am receiving a 2105
runtime error. I have an error handler that looks for the 2105 error and
should exit the sub, but I still get the error message. What is really odd
is that I copied the code from another database of mine (that works fine),
but not in this database. Any help would be appreciated. Thanks in advance.
I must be tired.
Private Sub cmdNext_Click()
On Error GoTo Err_cmdNext_Click
DoCmd.GoToRecord , , acNext
Exit_cmdNext_Click:
Exit Sub
Err_cmdNext_Click:
If Err.Number = 2105 Then
DoCmd.GoToRecord , , acLast
Resume Exit_cmdNext_Click
Else
MsgBox Err.Number & " " & Err.Description
Resume Exit_cmdNext_Click
End If
End Sub
I have created my own set of navigation buttons but I am receiving a 2105
runtime error. I have an error handler that looks for the 2105 error and
should exit the sub, but I still get the error message. What is really odd
is that I copied the code from another database of mine (that works fine),
but not in this database. Any help would be appreciated. Thanks in advance.
I must be tired.
Private Sub cmdNext_Click()
On Error GoTo Err_cmdNext_Click
DoCmd.GoToRecord , , acNext
Exit_cmdNext_Click:
Exit Sub
Err_cmdNext_Click:
If Err.Number = 2105 Then
DoCmd.GoToRecord , , acLast
Resume Exit_cmdNext_Click
Else
MsgBox Err.Number & " " & Err.Description
Resume Exit_cmdNext_Click
End If
End Sub