Re: Group Calculations and "repeat Section"

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



"Gordzilla" wrote

> I have a bunch of simple calculations,
> based on the grouping of items in a
> report. There is a grup header and
> footer. The foot contains a total count
> of detail records and subsets of various
> criteria and calculated percentages.
> My problem is that some of the groups
> span multiple pages and I have the
> "repeat section" set to yes in the Group
> header. My calculations only seem
> to work when the group is on one page
> anything over a page only calculates on
> the details contained on the last page with
> a group header. The group header has
> code behind which resets all the variables
> back to zero.

It seems to me that you are going to have to redesign your calculations so
that the header does not reset the values to zero when it prints on each
page because of the repeat factor, or you are going to have to eliminate the
repeat factor, or you are going to have to obtain the results in another
way.

Perhaps you could reset the values in the Footer, or only when the value on
which you are grouping changes, if your calculations must be done in code as
you have them now, but...

Because the firing of events is difficult to predict, I try to avoid doing
calculations in event code. When possible I use calculated Fields in the
Query that is RecordSource for the Report, or calculated Controls within the
Report itself.

Larry Linson
Microsoft Access MVP




.



Relevant Pages

  • Group Calculations and "repeat Section"
    ... There is a grup header and footer. ... detail records and subsets of various criteria and calculated percentages. ... My calculations only seem ... the details contained on the last page with a group header. ...
    (microsoft.public.access.reports)
  • Re: In Excel ### appears in the cell, not the sum. Why?
    ... header -- on the right edge and double click... ... or click and drag. ... How can I get the actual sum to appear? ... is only occuring for 1 set of the calculations. ...
    (microsoft.public.excel.newusers)
  • conversion from type character to type real
    ... calculations so I have to read them out of the header an convert them ... Crissy ... Prev by Date: ...
    (comp.lang.fortran)
  • Re: Advanced Filter
    ... The header being in row2 should make no difference. ... Date calculations ... can be tricky. ...
    (microsoft.public.excel.programming)
  • Re: parsing txt file
    ... I agree but is there a way to reset the variable only if it meets certain ... the next 49 rows then the variable is beiing reset to the new col004 value ... > header but by the look of it you have many. ... The txt file is in fact a report that has header, ...
    (microsoft.public.sqlserver.dts)