Hi all, I have a dilemma, I have looked through the internet and found many ways of setting focus on a form when it opens, that's fine and dandy, however, I would like to set the focus from another from from a command button.
Hi all, I have a dilemma, I have looked through the internet and found many ways of setting focus on a form when it opens, that's fine and dandy, however, I would like to set the focus from another from from a command button.
Just go through the Forms collection. http://access.mvps.org/access/forms/frm0031.htm
Hi thanks for your quick reply, but your answer refers to forms and subforms, I have a combobox and command button on entirely different form, the user chooses a record from the combo then clicks the command button which opens the form to that specific record, what I want to achieve is when that other form opens to go to a specific field for data entry, but not want the form to open to that field when it opens from another method, hope that makes sense.
Forms.YourOtherFormName.TheControlYouWant.SetFocus.
...using your values of course.
Hi ruralGuy, I beat you to it, just came on to tell you I've solved it with exactly the same solution, just came to me like a eureka moment, but thanks for confirming my solution
Glad we're on the same track. Thanks for posting back with your success.