Updating subform with query results

phil-007

Registered User.
Local time
Today, 19:02
Joined
Jul 16, 2013
Messages
28
Hi All,

I have a basic DB for recording supplier records, you enter a supplier ID and it performs Dlookups to run and display query results on the same form. That part works fine.

I've added a subform and linked it to an existing query which returns the suppliers top selling lines and the query picks up the supplier from the ID field on the main form, however when I enter a new id the subform doesn't update with the results specific to that supplier.

So I think I need a way of getting the subform to re-run the query each time I update the supplier ID field, but I can't see an option for this in the subform properties

Can this be done?

Many Thanks

Phil
 
You could put code in the AfterUpdate event of the main form's ID control that requeries the subform.
 
I meant on the subform's ID field.

This all sounds kind of complicated. Are you sure there isn't a simpler way to accomplish this??
 

Users who are viewing this thread

Back
Top Bottom