Hi all,
This seems like it would be fairly simple, but quite frankly I can't
figure it out. I have combed through other posts and still can't get
it working.
I have two tables (Students, Emergency Contacts) and two seperate main
entry forms for each table (frmNewStudent & frmEmergencyContacts). I
wanted to put a command button on frmNewStudent that when clicked
would open up frmEmergencyContacts to an add new record so that a user
can add a completly new emergency contact record to the Emergency
contact table.
I hope that makes sense.
I haven't been able to get it working. Code I'm currently using is
spitting back the error "Action or method requires a Form Name
argument". Code I have used previously has simply taken me to the
first record in the EmergencyContacts recordset. I just want the form
to ADD a record to EmergencyContacts.
Code in use:
Private Sub Command76_Click()
On Error GoTo Err_Command76_Click
DoCmd.OpenForm frmEmergencyContacts
DoCmd.GoToRecord , , acNewRec
Exit_Command76_Click:
Exit Sub
Err_Command76_Click:
MsgBox Err.Description
Resume Exit_Command76_Click
End Sub
---
Thanks for any help. I'm struggling.
Abby