Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

In Subform set focus to the new record

Status
Not open for further replies.

qshaz

Technical User
Feb 1, 2002
17
0
0
AE
I have a subform and a button called add new record. When the main form is also a new record, and someone clicks on the subforms addnew record button, naturally they can see the new record. The subform is a continous form and takes a small space of the main form. So when there are many new records, and someone clicks add new record, the focus does not go to the blank new record, and they have to scroll down to see this. How do I do this?

Thanks
Shazia
 
I would simply setfocus on the field in that record you wish to be in.

For example,

DoCmd.GoToRecord , , acNewRec
Me.EmployerName.SetFocus

This brings the focus in the new record to the EmployerName field.

I hope that helps.

Karen
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top