Automatic Sum Updates

T

Tom Bock

On a form, does anyone know how to automatically update a textbox that
displays the SUM of multiple textboxes.

For instance, I have Box1 and Box2. Box1's value is 5; Box2's value is 3.

The BoxSum automatically displays 8 right now. However, if I were to
change any of the values (e.g. 5 to 4 for Box 1) then the BoxSum does not
automatically gets updated.

I tried to put an AfterChange event into Box1 and Box2 with the following
code:

BoxSum.Requery


However, this still does not work. Any suggestions?!?

Thanks,
Tom
 
T

Tom

Joe:

PERFECT! That works great!!!



--
Thanks so much for the info,
Tom


Joe Fallon said:
Did you try this for BoxSum:
=[Box1] + [Box2]
--
Joe Fallon
Access MVP



Tom Bock said:
On a form, does anyone know how to automatically update a textbox that
displays the SUM of multiple textboxes.

For instance, I have Box1 and Box2. Box1's value is 5; Box2's value is 3.

The BoxSum automatically displays 8 right now. However, if I were to
change any of the values (e.g. 5 to 4 for Box 1) then the BoxSum does not
automatically gets updated.

I tried to put an AfterChange event into Box1 and Box2 with the following
code:

BoxSum.Requery


However, this still does not work. Any suggestions?!?

Thanks,
Tom
 

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

Similar Threads


Top