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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Updating Subform to Requery Second Subform

Status
Not open for further replies.

skoutr1

Technical User
Aug 9, 2001
22
0
0
US
Looking for VBA to do the following (some names have been changed to protect the innocent):

I have a form (frmLog) based on a table (tblLog) with 2 subforms (sfrmOne and sfrmTwo). sfrmOne Record Source is a table (tblOne) and sfrmTwo Record Source is a query (qryTwo). Forms and subforms are linked via a date field (dteLog).

When a record is updated or added in sfrmOne, I want sfrmTwo to requery/recalculate to update calculated values from sfrmOne.

If I navigate away from the edited record in frmLog, and then return, the updated calculations are displayed. I would like the calculation to be "live" as records are changed.
 
PROBLEM SOLVED!

Placed the following for the OnExit Event for sfrmOne

Forms!frmLog.Refresh
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top