Requery Shows To Much

  • Thread starter Thread starter DS
  • Start date Start date
D

DS

Whenever I add a record to a Subform I have a Requery on the Subform so
that the calculated control shows the new amount, except when I requery
every record shows up, not just the current set. Anyway around this?

Forms!Payment.PaymentAmount.Requery

Thanks
DS
 
Are you requerying the main form or the subform? Here's an example I use to
requery a subform once the main form data has changed:

[Forms]![frmHoursEntry]![frmHoursEntry subform].Requery

I query the form, not the field/control.
Mich
 
M said:
Are you requerying the main form or the subform? Here's an example I use to
requery a subform once the main form data has changed:

[Forms]![frmHoursEntry]![frmHoursEntry subform].Requery

I query the form, not the field/control.
Mich

Whenever I add a record to a Subform I have a Requery on the Subform so
that the calculated control shows the new amount, except when I requery
every record shows up, not just the current set. Anyway around this?

Forms!Payment.PaymentAmount.Requery

Thanks
DS
The Main Form stays the same...The SubForm has records added to it from
a popup form. I have a control on the subform that sums p the dollar
amounts on the subform. The Subform is requering but its showing all of
the records in the subform...not just those that are pretaining to the
current record on the Main Form.
Thanks
DS
 
The Subform is requering but its showing all of
the records in the subform...not just those that are pretaining to the
current record on the Main Form.

Then there must be something wrong with its recordsource, or with the
master/child link fields. What are these?

If you just want a calculation to be current, use Recalc rather than
Requery.

John W. Vinson[MVP]
 
John said:
Then there must be something wrong with its recordsource, or with the
master/child link fields. What are these?

If you just want a calculation to be current, use Recalc rather than
Requery.

John W. Vinson[MVP]
Thanks John.....Again!
The ReCalc worked.
DS
 
Back
Top