Sums

S

Sarah Stockton

I have a report that has Text46 and Text48, these text boxes have nested IIF
statements in them and are located in the VehicleNumber header. My IIF
statements work great. Now the problem is: I want to add text46 and text48
together in the Date Footer section. I have entered the following formula
=Sum([Text46])+([Text48])
when my report runs it doesn't reconize Text46 it asks for a parementer value.

I have checked the spelling, check that that is the name not the caption. I
am lost!
Please help.

Thanks
sks
 
S

Sprinks

Hi, Sarah.

This one isn't intuitive to me, either, but you need to sum your whole IIf
statements in the footer:

=Sum(IIf Statement Number 1) + Sum([IIfStatement Number 2)

Hope that helps.
Sprinks
 
J

John Vinson

I have a report that has Text46 and Text48, these text boxes have nested IIF
statements in them and are located in the VehicleNumber header. My IIF
statements work great. Now the problem is: I want to add text46 and text48
together in the Date Footer section. I have entered the following formula
=Sum([Text46])+([Text48])
when my report runs it doesn't reconize Text46 it asks for a parementer value.

A Sum cannot refer to *textboxes* on a report - only to *fields* in
the report's Recordsource.

Try moving the IIF statements into the Query upon which the form is
based; give them names more meaningful than Text46. You should then be
able to bind report textboxes to those fields, and use

=Sum([FieldA] + [FieldB])

in the footer section.

John W. Vinson[MVP]
 
S

Sarah Stockton

Shortly after I submitted this I figured it out.
Yes I had to sum the entire IIF statements. I had tried that before but I
had my parentheses wrong.

Thanks for the help

Sarah


John Vinson said:
I have a report that has Text46 and Text48, these text boxes have nested IIF
statements in them and are located in the VehicleNumber header. My IIF
statements work great. Now the problem is: I want to add text46 and text48
together in the Date Footer section. I have entered the following formula
=Sum([Text46])+([Text48])
when my report runs it doesn't reconize Text46 it asks for a parementer value.

A Sum cannot refer to *textboxes* on a report - only to *fields* in
the report's Recordsource.

Try moving the IIF statements into the Query upon which the form is
based; give them names more meaningful than Text46. You should then be
able to bind report textboxes to those fields, and use

=Sum([FieldA] + [FieldB])

in the footer section.

John W. Vinson[MVP]
 
Top