Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Navigation Buttons Advance Main Form 1

Status
Not open for further replies.

wgechter

MIS
Jul 24, 2002
85
US
I have a form with a subform in it. I have turned off the navigation buttons in my subform and only have navigation buttons on my main form. When I click the button for the next record I want it to advance the main forms record. Currently, it is advancing the subforms records. How do I do this? Thanks
 
whechter
Are you sure that everything is set up correctly?

I assume that the main form and the subform are synchronized by the record identification. And that the main form and subform records are in a one-to-many relationship.

The navigation buttons on the main form and the navigation buttons on the subform operate independently. The main form buttons advance the main form. The subform buttons advance subform records for the record that is in view in the main form.

Tom
 
No, I'm not sure everything is set up corretly. But I took a form that is working correctly and copied it and created this new form. Only thing that changed was the name of the form and the Record Source which is a different query. I had this problem before when I first created the original form and somehow easily fixed it. Now I have no clue. Let me know.
 
wgechter
First of all, you will have to make sure that the form's RecordSource is set to the correct query.

Secondly, you will have to make sure that the subform's record source is set to the correct table or query.

Thirdly, in the subform, make sure that the LinkChildFields and LinkMasterFields are correctly set.

You may find it easier to first of all set the main form to the correct RecordSource, then delete the subform and then add a subform in again, and that time things will probably link up properly.

Tom
 
Tom, Thank you. The RecordSource is correct. I want the form to look exactly identical and work exactly identical but use a different query. So that is correct for both forms and subforms. The linkchildfields and linkmasterfields are exactly the same for each as well. This is why I don't understand why this form advances different through navigation then the original form. I did try to delete the subform and re-enter it. That did not help. Honestly, when I did it the first time it was a really easy solution such as grouping or sorting or something, but I'm drawing a blank now. Thanks, wgechter
 
I got it. Thanks for your help. When I started looking at the difference in my queries it was a matter of adding a field from a wrong table that was not letting me order by a certain field in the master form which then wouldn't navigate on them correctly. If that made sense. It's fixed now. Thank you!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top