navigation

  • Thread starter Thread starter SAC
  • Start date Start date
S

SAC

How do I go from a dropdown box on a main form to a control on a subform?

Forms![frmARTRH]![ARTRL subform].Form![Qty].setfocus doesn't work.

and docmd.gotocontrol "Forms![frmARTRH]![ARTRL subform].Form![Qty]" doesn't
seem to work.

Thanks.
 
Set the Focus to the SubformControl first.

Forms!MainForm.SubformControl.SetFocus

then your statement.

HTH
Van T. Dinh
MVP (Access)
 
To set focus to the subform control from the main form, you must first set
focus to the subform control itself:

me.sfrmSub1.setfocus
me.sfrmSub1.form.txtMyControl.setfocus
 
Thanks!

Van T. Dinh said:
Set the Focus to the SubformControl first.

Forms!MainForm.SubformControl.SetFocus

then your statement.

HTH
Van T. Dinh
MVP (Access)



-----Original Message-----
How do I go from a dropdown box on a main form to a control on a subform?

Forms![frmARTRH]![ARTRL subform].Form![Qty].setfocus doesn't work.

and docmd.gotocontrol "Forms![frmARTRH]![ARTRL subform].Form![Qty]" doesn't
seem to work.

Thanks.



.
 
Thanks!
Sandra Daigle said:
To set focus to the subform control from the main form, you must first set
focus to the subform control itself:

me.sfrmSub1.setfocus
me.sfrmSub1.form.txtMyControl.setfocus

--
Sandra Daigle
[Microsoft Access MVP]
For the benefit of others please post all replies to this newsgroup.
How do I go from a dropdown box on a main form to a control on a subform?

Forms![frmARTRH]![ARTRL subform].Form![Qty].setfocus doesn't work.

and docmd.gotocontrol "Forms![frmARTRH]![ARTRL subform].Form![Qty]"
doesn't seem to work.

Thanks.
 
Back
Top