Requery a sub form

bsnapool

Registered User.
Local time
Today, 16:51
Joined
Nov 17, 2006
Messages
96
Hi All

What event should i Use to update a subform which is based on a query to update when a new record is added?

I am using me.requery but I dont know what event and what form it should go in???

Any help would be much appreciated

Thanks

Andrwe
 
You requery the subform based on any event which changes the cirteria for the subform. Usually that criteria is on the main form and is not usually on the subform, so on the main form's (criteria) field which changes AfterUpdate event requery the subform using. There maybe multiple criteria fields. REquery after a change in each:

PHP:
Form!MainFormName!SubFormName.Requery

If the subform's Linki Master Field and Link Child field properties are properly set, no querying will be necessary. That of course, assumes that the criteria is on the main form, no another subform.

If the criteria is on a second that's another case, except that uyou use the same requery (above) of the subform which has the criteria AfterUpdate event.
 

Users who are viewing this thread

Back
Top Bottom