By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,157 Members | 891 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,157 IT Pros & Developers. It's quick & easy.

? about displaying total from subform on main form

P: n/a
I've got an A2K form with a subform based on a query. This query has
a checkbox and an amount field and returns records if checkbox is
checked. I Dsum the amount field and display on the main form. If
the user unchecks the box, I want the corresponding amount subtracted
from the total. If they recheck the box, the amount is to be added.
I want all records to appear on the subform even after unchecking
them. This works fine...except...

I'm unable to get the total to display correctly. It appears that the
total is always 1 amount off. For example, if the total is $25,000
and amount 1 is $1000 and amount 2 is $500, then unchecking amount 1
does not requery the total. Unchecking amount 2 requeries the total
but the total displays as $24,000. The only way I can get the total
to display correctly is by requerying the subform after every checkbox
update but then only the checked records are displayed.

I use a DSum in the subform to total up the amounts...store that
result in a textbox, then display that textbox on the main form.

Any help or advice is appreciated.
Nov 12 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.