Access - form- new record

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a form, and a sub form. WHen you are done entering data on the sub
form and click add new records (>*) I want to return to the the main form -
but the cursor stays on the sub form. I can't find a way to attach a macro
when you click new record to close the sub form and open the main form. HELP!
 
You can click the new record navigation button on the main form to go to a
new record simultaneously in the main form and subfom. Put the following
code in the Current event of the main form:
If Me.NewRecord Then
Me!NameOfFirstFieldOn MainForm.SetFocus
End If
The code will take you to the first field on the main form when you go to a
new record.

PC Datasheet
Providing Customers A Resource For Help With Access, Excel And Word
Applications
(e-mail address removed)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top