Summarizing control not in recordset

henkus

Registered User.
Local time
Today, 12:03
Joined
Jun 4, 2008
Messages
14
Hi,

I populate a continous form with a bunch of textboxes. Some are from from query, and some are calculations based on the data in the recordset. How do I get Access to present a sum formula of one of the calculated fields?
=sum([Box1]) works if [Box1] is in recordset, but not if it's a calculated field...

I.e.:
Textbox1=Field A in table
Textbox2=Field B in table
Textbox3= =[Textbox1]+[Textbox2]

What I want:
Textbox4= =sum([Textbox3])

I guess I could write =sum([Textbox1]+[Textbox2]), but in reality, the formula is really long and based on a lot of fields...

/henkus
 
First, I think, you need to get rid of the double equal signs. When using aggregate functions, such as Sum() against calculated fields, you have to include the calculations, In other words, if Textbox3 is a calculated field, you can't use

Textbox4= sum([Textbox3])

but rather something like

Textbox4= =sum([Textbox1]+[Textbox2])

as you yourself suggested. The number of fields and length of the calculation doesn't really change the fact that you have to do this.
 

Users who are viewing this thread

Back
Top Bottom