471,046 Members | 846 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,046 software developers and data experts.

? about displaying total from subform on main form

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
0 1746

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

30 posts views Thread by Shannan Casteel via AccessMonster.com | last post: by
16 posts views Thread by ken | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.