justlearning2003
Technical User
Hey,
Do anyone see any problem with this code.
MsgBox "Your record has been sent to the database"
If rstblAllMarkErrorUpdate.RecordCount > 0 Then
On Error GoTo Err_Command26_Click
DoCmd.GoToRecord , , acNext
Err_Command26_Click:
Select Case Err.Number
Case 2105:
MsgBox "There are no more records to view."
DoCmd.Close
DoCmd.OpenForm "Team Leader Agent Feeback"
End Select
End If
Once the code reaches the Msgbox and there are more records to view the code do not go inside the if statement.
Any ideas?
Thanks
Do anyone see any problem with this code.
MsgBox "Your record has been sent to the database"
If rstblAllMarkErrorUpdate.RecordCount > 0 Then
On Error GoTo Err_Command26_Click
DoCmd.GoToRecord , , acNext
Err_Command26_Click:
Select Case Err.Number
Case 2105:
MsgBox "There are no more records to view."
DoCmd.Close
DoCmd.OpenForm "Team Leader Agent Feeback"
End Select
End If
Once the code reaches the Msgbox and there are more records to view the code do not go inside the if statement.
Any ideas?
Thanks