From: cinnie on
My report has a column of numbers. Below the column, I would like to show a
text box with the sum of these numbers. In Excel I would just use something
like "= Sum(C3:C56)", but I don't know how to do this in Access. My real
problem is that each report has a different number of rows. Any clues??
Thanks
--
cinnie
From: Al Campagna on
cinnie,
If you had an uncalculated bound text control named Price, with
numeric values...
= Sum(Price)
would yield the Sum of Price in any Group Footer, or Report Footer.
--
hth
Al Campagna
Microsoft Access MVP 2007-2009
http://home.comcast.net/~cccsolutions/index.html

"Find a job that you love... and you'll never work a day in your life."

"cinnie" <cinnie(a)discussions.microsoft.com> wrote in message
news:25F8D0FF-00E3-433E-867A-6390168C9357(a)microsoft.com...
> My report has a column of numbers. Below the column, I would like to show
> a
> text box with the sum of these numbers. In Excel I would just use
> something
> like "= Sum(C3:C56)", but I don't know how to do this in Access. My real
> problem is that each report has a different number of rows. Any clues??
> Thanks
> --
> cinnie


From: John Spencer on
Use the report footer or a group footer (report footer if you want to sum the
entire report and group footer if you want to subtotal by groups of records)
and add a control to the footer with its control source set to sum the
relevant field. Something Like

ControlSource: =Sum([Amount])



John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County

cinnie wrote:
> My report has a column of numbers. Below the column, I would like to show a
> text box with the sum of these numbers. In Excel I would just use something
> like "= Sum(C3:C56)", but I don't know how to do this in Access. My real
> problem is that each report has a different number of rows. Any clues??
> Thanks
From: cinnie on
thanks Al and John. I think the reason Control Source: = Sum([txtA])
doesn't work is that txtA is from a XTab query. It is calculated based on a
Count. Does that mean I can't use 'Sum([txtA])' to sum these values? thanks
again
--
cinnie


"Al Campagna" wrote:

> cinnie,
> If you had an uncalculated bound text control named Price, with
> numeric values...
> = Sum(Price)
> would yield the Sum of Price in any Group Footer, or Report Footer.
> --
> hth
> Al Campagna
> Microsoft Access MVP 2007-2009
> http://home.comcast.net/~cccsolutions/index.html
>
> "Find a job that you love... and you'll never work a day in your life."
>
> "cinnie" <cinnie(a)discussions.microsoft.com> wrote in message
> news:25F8D0FF-00E3-433E-867A-6390168C9357(a)microsoft.com...
> > My report has a column of numbers. Below the column, I would like to show
> > a
> > text box with the sum of these numbers. In Excel I would just use
> > something
> > like "= Sum(C3:C56)", but I don't know how to do this in Access. My real
> > problem is that each report has a different number of rows. Any clues??
> > Thanks
> > --
> > cinnie
>
>
> .
>
From: Duane Hookom on
You can Sum() numeric values from crosstab or other queries. Make sure you
are not attempting to sum in the Page Footer section.

I'm confused why you would name a column/field "txtA" when "txt" is
generally a prefix for either a text box or a field/variable storing a
text/string value.

If it is a text box, you can't Sum() a control.

--
Duane Hookom
MS Access MVP


"cinnie" <cinnie(a)discussions.microsoft.com> wrote in message
news:FC007585-C082-4345-A5B3-343996949DCD(a)microsoft.com...
> thanks Al and John. I think the reason Control Source: = Sum([txtA])
> doesn't work is that txtA is from a XTab query. It is calculated based on
> a
> Count. Does that mean I can't use 'Sum([txtA])' to sum these values?
> thanks
> again
> --
> cinnie
>
>
> "Al Campagna" wrote:
>
>> cinnie,
>> If you had an uncalculated bound text control named Price, with
>> numeric values...
>> = Sum(Price)
>> would yield the Sum of Price in any Group Footer, or Report Footer.
>> --
>> hth
>> Al Campagna
>> Microsoft Access MVP 2007-2009
>> http://home.comcast.net/~cccsolutions/index.html
>>
>> "Find a job that you love... and you'll never work a day in your
>> life."
>>
>> "cinnie" <cinnie(a)discussions.microsoft.com> wrote in message
>> news:25F8D0FF-00E3-433E-867A-6390168C9357(a)microsoft.com...
>> > My report has a column of numbers. Below the column, I would like to
>> > show
>> > a
>> > text box with the sum of these numbers. In Excel I would just use
>> > something
>> > like "= Sum(C3:C56)", but I don't know how to do this in Access. My
>> > real
>> > problem is that each report has a different number of rows. Any
>> > clues??
>> > Thanks
>> > --
>> > cinnie
>>
>>
>> .
>>