Go To Next Record on nested subform

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

Guest

Hi

I need to be able to go to a new record on a nested subform the only problem
is i need to be able to do it using the name of the subform as a string
rather than a direct reference.

So like, for subform called month1 go to next record.

I have 12 subforms (one subform used 12 times) one for each month and i have
to go to the relevant month.

Any help would be greatly appreciated

Cheers

Danny
 
Presumably this code goes into the module of the main form?

SetFocus to the subform control.
Then SetFocus to a control within the subform.
Then go to the new record.

With Me("month1")
.SetFocus
.Form!Text1.SetFocus
If Not .Form.NewRecord Then
RunCommand acCmdRecordsGotoNew
End if
End With
 

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

Similar Threads


Back
Top