Setting focus on subform record 
Author Message
 Setting focus on subform record

How do I open a form and have the focus set to a given
record in its subform?


Mon, 29 Aug 2005 03:35:18 GMT  
 Setting focus on subform record
hi there
in the open event of the main form, write
Me.[SubForm's Control Name Comes Here]!
DesiredControl.SetFocus

Erez.

Quote:
>-----Original Message-----
>How do I open a form and have the focus set to a given
>record in its subform?
>.



Mon, 29 Aug 2005 08:41:28 GMT  
 Setting focus on subform record
Actually, you  need two set focus commands: the first to set focus to the
main form's subform control, and the second to set focus to the control on
the subform.

Me.[SubForm's Control Name Comes Here].SetFocus
Me.[SubForm's Control Name Comes Here]!DesiredControl.SetFocus

SubForm's Control Name Comes Here should be replaced by the actual name of
the subform control (the control that holds the subform).

--
       Ken Snell
<MS ACCESS MVP>


Quote:
> hi there
> in the open event of the main form, write
> Me.[SubForm's Control Name Comes Here]!
> DesiredControl.SetFocus

> Erez.
> >-----Original Message-----
> >How do I open a form and have the focus set to a given
> >record in its subform?
> >.



Mon, 29 Aug 2005 10:40:09 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. set focus to subform record

2. find record in and set focus to that record in a subform

3. Set focus/highlight subform record after main form requery?

4. Create new record and then set focus to it in a subform

5. Subform - set focus to double-clicked record

6. Setting Focus to last record on a subform

7. Setting Focus to Subform during new record

8. set focus to new record on subform?

9. set focus to a particular record in a subform

10. set record focus based on selection of subform


 
Powered by phpBB® Forum Software © phpBB Group