Custom Nav Buttons and Subforms -- Focus?

lford91

Registered User.
Local time
Yesterday, 19:38
Joined
Jul 12, 2013
Messages
17
I have made custom navigation buttons and they are at the top of my form. I have tabs with different categories, some of which have subforms. I have navigation buttons on the subforms for looking through those records. My problem is that if I am in a field on a subform and want to move to the next record of the MAIN form and click on the navigation buttons at the top of the form, instead of moving to the next/previous/first/last record of the main form, the buttons move within the SUBFORM. How can I make it so that even if I am currently in a field in a subform, I can click on the navigation button on the main form and move to the appropriate record on the main form not the subform.

The main form is people. One of the subforms is in a tab for addresses. A person can have multiple addresses (work, home, etc...). I want the custom nav buttons at the top to only move person to person, not address to address.

What do I do to make this happen?

:banghead:
 
I think you need to return Focus to the Main Form before executing the code in your Main Form Nav buttons. In your Nav Buttons, I'd try moving Focus to a Control on the Main Form and then run the nav code.

Linq ;0)>
 
What would the code be? I had tried this before in various ways and it wasn't working. Giving error like "Object required" or something about it not being a valid object for the action? I am self taught and code is still a mystery to me sometimes... Sorry.
 
Never mind. It wouldn't let me do it because I was trying to set focus on an object that was not visible. Tried it on one that was visible and it worked. Thank you for your help!
 

Users who are viewing this thread

Back
Top Bottom