Group:  Microsoft Access ยป microsoft.public.access.formscoding
Thread: cummulative sums

Geek News

cummulative sums
Gator 12/18/2008 3:52:01 PM
I have a form where I enter a date and amounts. It is set up where several
records may have the same date but different amounts. Also, earlier dates
could be entered after later dates. I have a text field where I am deducting
a cummulative amount from a fixed amount. When I am at any given record, I
would like to take the cummulative amount of a field for the year up to that
date.
The field that I use to give me the cummulative sum for the year is
=DSum("[08rt]","Collections","Year([DatePd]) =" & Year([txtDate])), but this
remains fixed no matter what day I display. How can I use a field that will
show me the cumm sum for the year up to and including the day displayed in
the date textbox (DatePd)?
RE: cummulative sums
Beetle 12/18/2008 6:12:18 PM
=DSum("[08rt]","Collections","[DatePd] <=#" & [txtDate] & "#")
--
_________

Sean Bailey


"Gator" wrote:

[Quoted Text]
> I have a form where I enter a date and amounts. It is set up where several
> records may have the same date but different amounts. Also, earlier dates
> could be entered after later dates. I have a text field where I am deducting
> a cummulative amount from a fixed amount. When I am at any given record, I
> would like to take the cummulative amount of a field for the year up to that
> date.
> The field that I use to give me the cummulative sum for the year is
> =DSum("[08rt]","Collections","Year([DatePd]) =" & Year([txtDate])), but this
> remains fixed no matter what day I display. How can I use a field that will
> show me the cumm sum for the year up to and including the day displayed in
> the date textbox (DatePd)?

Home | Search | Terms | Imprint Contact
Newsgroups Reader - provided by WiredBox.Net