Tab from Form to Subform?

  • Thread starter Thread starter James T.
  • Start date Start date
J

James T.

Access 2000

I have a form that I would like the user to be able to tab
from the last field in the form to the first field in the
subform, ie. from PhoneNumber in Form, to DateAdded in
SubForm.

Any help appreciated.

Thanks,
James
 
Is this not working now on your form? What are you seeing? Do you want this
to happen programmatically? Do you want the first control in the subform to
get the focus each time you enter the subform? More info, please.
 
In line ...
-----Original Message-----
Is this not working now on your form? No.

What are you seeing? I have a form that has a list
of "Owners". The subform is a list of apartments that each
Owner has for lease.

Do you want this to happen programmatically? No sure what
you mean. If you mean as an event, macro etc., it doesn't
matter, just so it will work.

Do you want the first control in the subform to get the
focus each time you enter the subform? Yes, I want to be
able to TAB from the last field in the Owners Form
(PhoneNumber) to the first field (DateAdded) in the
subform.

Does that help?

James

More info, please.
 
Assuming that the subform control (the control that holds the subform) is
Enabled and not Locked, tabbing from one control to another should tab you
into the subform when the tab order gets to the subform control. You can
adjust the tab order by opening the form in design view, and clicking View |
Tab Order to see the list of controls and the order in which they'll be
"reached" by tabbing.

If you always want the first control in the subform to get the focus
whenever you tab "into" the subform, use the subform control's On Enter
property to run code that sets the focus to that first control on the
subform:

Private Sub SubformControlName_Enter(Cancel As Integer)
Me.SubformControlName.Form.FirstControlOnSubform.SetFocus
End Sub
 
You just need to right click on the form in design and select tab order.
Include your subform in the tab order and it should go to the first field in
you subform after the last field in your main form. Hope this is what you're
looking for.

LadyCES
 
This may be a silly question, but I have done that and can
only set the Tab order for the form OR the subform
separtely. How do you view both tab orders, on the form
and subform, at the same time?

Thanks,
James
 
Duh!! I had the subform in the form footer! When I moved
it up to the form itself, I was able to set the Tab order,
BUT ... now I have a scroll bar in the subform that I
can't adjust! It scrolls over to a blank area. I didn't
have that problem when it was in the footer. I have tried
several things to no avail.
Any thoughts?
Thanks!

James
 
Turn off the scroll bars in the form that is serving as the subform. Also
narrow the width of the form that is serving as the subform so that there is
not any "empty" space to the right of the controls on that form.
 
I tried that, resized both ways, scroll bars set to
neither on both the subform and the form, navigation to
No, deleted the subform, created a Query and dropped that
in the form, same problem. Did a Google search and found a
lot of articles when the scroll bar would NOT show up, but
nothing on if it is constantly too big.

Any thoughts?

James
 
What view are you using for the subform? Datasheet? If yes, I don't believe
you can "turn off" the scroll bar in that view.
 
Back
Top