T
Tracy
Hi,
I added a command button to my main form that would allow the user to add a
new record. However, when I click on it I get an error message saying, 'You
can't go to specified record.' Here is my code:
Private Sub AddRec_Click()
On Error GoTo Err_AddRec_Click
DoCmd.GoToRecord , , acNewRec
Exit_AddRec_Click:
Exit Sub
Err_AddRec_Click:
MsgBox Err.Description
Resume Exit_AddRec_Click
End Sub
Any suggestions on how I can get this to function correctly? Thanks.
I added a command button to my main form that would allow the user to add a
new record. However, when I click on it I get an error message saying, 'You
can't go to specified record.' Here is my code:
Private Sub AddRec_Click()
On Error GoTo Err_AddRec_Click
DoCmd.GoToRecord , , acNewRec
Exit_AddRec_Click:
Exit Sub
Err_AddRec_Click:
MsgBox Err.Description
Resume Exit_AddRec_Click
End Sub
Any suggestions on how I can get this to function correctly? Thanks.