Setting SubForm Focus on a New Record in Datasheet view

C

CES

All,
I'm trying to have the focus of a subform go to a new record when the subform gets focus. I've tried the two combinations below but they don't seem to work.
Any suggestions would be appreciated... Thanks in advance. - CES


Private Sub Form_GotFocus()
'Forms!FormContacts!FormTransaction.SetFocus
'Forms!FormContacts!FormTransaction.Form!Me.Combo7.SetFocus

'Me.FormTransaction.SetFocus
'Me.FormTransaction.Form.Combo7.SetFocus


DoCmd.GoToRecord , , acNewRec
End Sub
 
K

kingston via AccessMonster.com

This should get you to the last record:

Me.FormTransaction.Form.Recordset.MoveLast

This might get you to a new record after that:

Me.FormTransaction.Form.Recordset.MoveNext
 

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

Top