How can I create a field to total another field in a report?

B

BCHS

Good Afternoon,
I am creating a report based on input in a table that calculates ticket
revenue from athletic events. I have the report completed and a total for
each line. The report is based on a query so I can select only specific
sports. How can I get an overall total for a particular sport? I have a
control placed in the footer, but can't seem to get the correct expression .
.. I get an error.
 
S

Stockwell43

Hi BCHS,

Open your report to Design view and click the Sorting and Grouping icon on
your toolbar. When it opens, selct the sport field and at the bottom create
header and footer. Place the Sports field in the header and a textbox in the
footer. Open the properties of the textbox in the footr and in the control
source type: =Sum([your field name you are trying to total]) and that should
do it. This will total for each sport. If you want the grand total for ALL
the sports on the report, copy the textbox and paste it in the Report Footer.

If I understood your question that should do the trick.
 
B

BCHS

I have tried this =Sum([text25]) is the control source and that is when I get
the error. "text25" is a field that contains an expression calculating the
total revenue generated from tickets sold for a single event, and I want the
field in the footer to calculate a total based on the events that are
selected when opening the report and typing in a specific sport.

I hope I am explaining what I am trying to do well enough.


Stockwell43 said:
Hi BCHS,

Open your report to Design view and click the Sorting and Grouping icon on
your toolbar. When it opens, selct the sport field and at the bottom create
header and footer. Place the Sports field in the header and a textbox in the
footer. Open the properties of the textbox in the footr and in the control
source type: =Sum([your field name you are trying to total]) and that should
do it. This will total for each sport. If you want the grand total for ALL
the sports on the report, copy the textbox and paste it in the Report Footer.

If I understood your question that should do the trick.

BCHS said:
Good Afternoon,
I am creating a report based on input in a table that calculates ticket
revenue from athletic events. I have the report completed and a total for
each line. The report is based on a query so I can select only specific
sports. How can I get an overall total for a particular sport? I have a
control placed in the footer, but can't seem to get the correct expression .
. I get an error.
 
S

Stockwell43

You have to use the name that is bound. Each time you create a text box it
will automatically be named Text23, Text 24 and so on. What is the name of
the field that is bound to the query?

BCHS said:
I have tried this =Sum([text25]) is the control source and that is when I get
the error. "text25" is a field that contains an expression calculating the
total revenue generated from tickets sold for a single event, and I want the
field in the footer to calculate a total based on the events that are
selected when opening the report and typing in a specific sport.

I hope I am explaining what I am trying to do well enough.


Stockwell43 said:
Hi BCHS,

Open your report to Design view and click the Sorting and Grouping icon on
your toolbar. When it opens, selct the sport field and at the bottom create
header and footer. Place the Sports field in the header and a textbox in the
footer. Open the properties of the textbox in the footr and in the control
source type: =Sum([your field name you are trying to total]) and that should
do it. This will total for each sport. If you want the grand total for ALL
the sports on the report, copy the textbox and paste it in the Report Footer.

If I understood your question that should do the trick.

BCHS said:
Good Afternoon,
I am creating a report based on input in a table that calculates ticket
revenue from athletic events. I have the report completed and a total for
each line. The report is based on a query so I can select only specific
sports. How can I get an overall total for a particular sport? I have a
control placed in the footer, but can't seem to get the correct expression .
. I get an error.
 
B

BCHS

It is named Text25 . . .

Stockwell43 said:
You have to use the name that is bound. Each time you create a text box it
will automatically be named Text23, Text 24 and so on. What is the name of
the field that is bound to the query?

BCHS said:
I have tried this =Sum([text25]) is the control source and that is when I get
the error. "text25" is a field that contains an expression calculating the
total revenue generated from tickets sold for a single event, and I want the
field in the footer to calculate a total based on the events that are
selected when opening the report and typing in a specific sport.

I hope I am explaining what I am trying to do well enough.


Stockwell43 said:
Hi BCHS,

Open your report to Design view and click the Sorting and Grouping icon on
your toolbar. When it opens, selct the sport field and at the bottom create
header and footer. Place the Sports field in the header and a textbox in the
footer. Open the properties of the textbox in the footr and in the control
source type: =Sum([your field name you are trying to total]) and that should
do it. This will total for each sport. If you want the grand total for ALL
the sports on the report, copy the textbox and paste it in the Report Footer.

If I understood your question that should do the trick.

:

Good Afternoon,
I am creating a report based on input in a table that calculates ticket
revenue from athletic events. I have the report completed and a total for
each line. The report is based on a query so I can select only specific
sports. How can I get an overall total for a particular sport? I have a
control placed in the footer, but can't seem to get the correct expression .
. I get an error.
 
J

John W. Vinson

It is named Text25 . . .

Stockwell43 said:
You have to use the name that is bound. Each time you create a text box it
will automatically be named Text23, Text 24 and so on. What is the name of
the field that is bound to the query?

BCHS said:
I have tried this =Sum([text25]) is the control source and that is when I get
the error. "text25" is a field that contains an expression calculating the
total revenue generated from tickets sold for a single event, and I want the
field in the footer to calculate a total based on the events that are
selected when opening the report and typing in a specific sport.

The problem is probably that you can Sum a *field value* but you cannot sum a
*control name*.

If Text25 is bound to some table field use =Sum([thatfieldname]). If Text25
has some expression as its control source use

=Sum(<the same expression>)
 

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

Top