Excluding Data from calculations

chad101

Registered User.
Local time
Today, 08:03
Joined
Dec 31, 2005
Messages
56
Pictures are worth a thousand words
subform.jpg


The image is a subform that is displayed in datasheet view when executed.
I have a check box called “exclude” The purpose of this is to exclude specific results from the data when performing calculations. In the footer I have several text boxes which I use to grab the Min, Max, Count, StDev, and Avg values i.e. “=Avg([inspectionResult])”. How can I exclude results which have a true value in their associated check box?

For example =Avg([inspectionResult]) WHERE [exclude] = false
The above expression does not work but explains what I want to accomplish.
 
I do it by creating different queries with different criteria. If you can figure out a way to choose the query, then use it as the record source of the subform and simply requery the subform.

I use a form of binary code, option groups and a select case to display different reports, but you could adapt it to refresh the record source of a subform quite easily
 

Attachments

Last edited:
It worked like a charm! :D

Sometimes the simplest things can stump you for hours on end lol. Cheers!
 

Users who are viewing this thread

Back
Top Bottom