Counter Counts Too Many

geraldcor

Registered User.
Local time
Today, 23:24
Joined
Jan 26, 2004
Messages
145
I have a report that only counts a field if it is within a certain criteria, there are three to choose from. It counts just fine based on the criteria but when there is a page break the next field that is counted is +2 instead of + 1. Example, after page one the three counters look like this: 21 20 7. On the next page, first record it looks like this: 21 20 9. I have an overall sample counter that just adds all of the rows and that is fine with no apparent page break errors. Can anyone help me with this. It is the last wrench in getting this report to work properly. I need this to add properly because eventually it will be adding upward of 300 fields. Thank you for any and all help.
Greg
 
Last edited:
300 RECORDS I should say.
 
well if you tell us how you derive your count we might be able to help ;)
 
Right, I forgot that little bit.
I have a global variable that corresponds to each counter text box. If Me.OtherElemnts <=5 Then sgCounter1 = sgCounter1+1. This is how it goes for the other two with the criteria being between 5 and 15 and greater than 15. I then set my text boxes on my report to equal these variables (in code). Does that make sense at all to you? Is that enough info?
Greg
 
then you'll have to reset them in one of the other format events back to one,
Page Header/Footer maybe
 
That is an excellent suggestion that I never thought of however, I don't want to set them to 1 and don't want to subtract 1 from all of them, only the counter that happens to meet the criteria for the first record of the page. Since we're on the subject of my painful report, this report has ten subreports. Each of these has a total count for the 3 different counters. Is there a way to add all of these calculated fields and display them on my main report? I have tried a few things that I pretty well knew wouldn't work but I tried anyway. Thanks for the speedy replies.
Greg
 

Users who are viewing this thread

Back
Top Bottom