Calculate total

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

I'm using Access 03. I have a main table called Events which tracks
marketing events such as dinners and seminars. I have a child table named
Costs. Each event has a main id# and is tied to the costs table - each event
can have multiple costs.

On my Cost form which is part of my main form, I have each cost line item
where I am listing a description, check # and amount. I created a query that
sums the total costs for each event. I have this query displayed as a text
box on my form so you can see the total amount spent on the event. Problem
is, I have to move to another record and back to that record for that amount
to recalculate. Is there any way I can have it recalc as I add line items so
it always displays the total amount? I tried to do a "requery" through a
macro, but it brings up the actual query screen, I just want the text box to
update. Perhaps I need to do this a different way. Thanks for your help!
 
It sounds as if your Cost form is a subform.
Try putting a FormFooter on that form, with a textbox whose ControlSource
looks like this:
=Sum(Amount)
This should auto-update as you add records to your subform.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top