Sounds Simple - but really struggling with my COUNT

yus786

I do OK
Local time
Today, 23:14
Joined
Jun 25, 2008
Messages
121
Part of my DB monitors attendance.

I would like to be able to COUNT the number of days a student has off, on holiday etc.

Sounds simple but I've been spending 2 days on it and just can't get it to work.

My form looks like this (sits within a form as a subform)

att1.jpg


I just want some boxes at the bottom that totals (on the main form or within the same subform) - example

Total Sick Days: 3
Total Holiday: 2

Etc etc

Can someone please help me and put me out of my misery.

I have attached a sample db

Thanks again
 

Attachments

I would create a crosstab and bind it to a form. I would then place the form in the footer of the main form so you can see the "recap" at the bottom.

Umm thanks.

These Crosstabs - are they difficult to do? Never done one before

Thanks again
 
Here is another way (see returned attachment)....check the Control Source property for the added Text Boxes.

Keep in mind though, it's not near as fast as a Crosstab Query that Pat had suggested.

.
 

Attachments

Here is another way (see returned attachment)....check the Control Source property for the added Text Boxes.

Keep in mind though, it's not near as fast as a Crosstab Query that Pat had suggested.

.

Thanks

I did play with Dcount but was getting the #Error. But i've check your control and now know why.

Thanks to both of you
 
Here is another way (see returned attachment)....check the Control Source property for the added Text Boxes.

Keep in mind though, it's not near as fast as a Crosstab Query that Pat had suggested.

.

A slight problem.

The form as it is works fine.

If i attach it to my main form as a subform (using the AddressID), i get the #Error in all the new fields you created.

Any idea why?

Something in the control that needs changing?

Cheers


EDIT: Found it. I had to change the Form! name

Thanks again
 
Last edited:

Users who are viewing this thread

Back
Top Bottom