Tabbing through form w/ subforms

  • Thread starter Thread starter Pamela
  • Start date Start date
P

Pamela

In reading other posts on this issue, I added a hidden, unbound text box to
subform1 that moves focus to subform2. Upon tabbing from the last field in
the last subform, the focus then returns to the first field in that subform -
not to the first field in form. When I try to click back into the first
field of the form and start the tab order again, upon hitting the hidden,
unbound text box, I get a run-time error 2110: Cannot move the focus to the
control frmLocation. How can I get it to do a single form continuous tab
order?

Thank you so much, in advance, for help!

Pamela
 
Perhaps you could use something like this in the Lost Focus event of the
last control in the subform:
If Me.Dirty Then Me.Dirty = False 'Save any edits
Me.Parent.SetFocus 'Focus back to the main form.
Me.Parent![SomeOtherControl].SetFocus
 
Back
Top