total noob deperate for help working out a formula

plugy

New Member
Joined
Nov 16, 2015
Messages
2
I am trying to make a register for my students.
Along the top being the date and student down the side
at the end i have present abcent and late.
I am trying to populate a sum for the month end.
The formula i have used is =COUNTIF(B3:F3,"p")
All date cells selected and if p inserted then it calculates a 1 in the attended cell.
same formula works for absent these are deleted from the total attenadence cell.
Problem comes when i have a cell called late, if i use the same formula it calculates the late but delets the attence figure.
I need it to populate the late cell and the present cell.
If the student has been present 3 days, then attendace cell reads 3, if he has been late the other two occations attendace should be 5, and the late cell 2.
Hope this akes sense.
Any help on the formulas i need to accomplish this will be greatly apprecited.
 

Excel Facts

Quick Sum
Select a range of cells. The total appears in bottom right of Excel screen. Right-click total to add Max, Min, Count, Average.
I am trying to make a register for my students.
Along the top being the date and student down the side
at the end i have present abcent and late.
I am trying to populate a sum for the month end.
The formula i have used is =COUNTIF(B3:F3,"p")
All date cells selected and if p inserted then it calculates a 1 in the attended cell.
same formula works for absent these are deleted from the total attenadence cell.
Problem comes when i have a cell called late, if i use the same formula it calculates the late but delets the attence figure.
I need it to populate the late cell and the present cell.
If the student has been present 3 days, then attendace cell reads 3, if he has been late the other two occations attendace should be 5, and the late cell 2.
Hope this akes sense.
Any help on the formulas i need to accomplish this will be greatly apprecited.

For Present and on time use;
Code:
=COUNTIF(B3:F3,"p")

For Total Attendance use (Counts late);
Code:
=SUM(COUNTIF(B3:F3,{"P","L"}))

For Late use;
Code:
=COUNTIF(B3:F3,"l")

For Absent use;
Code:
=COUNTIF(B3:F3,"a")

I hope this helps.
 
Upvote 0
For Present and on time use;
Code:
=COUNTIF(B3:F3,"p")

For Total Attendance use (Counts late);
Code:
=SUM(COUNTIF(B3:F3,{"P","L"}))

For Late use;
Code:
=COUNTIF(B3:F3,"l")

For Absent use;
Code:
=COUNTIF(B3:F3,"a")

I hope this helps.



This works great, my next question would be could i just keep extending the dates along the top thus shifting the "in" "out" "late" cells along with it, assume this would make the cells behave not as they should.

Another alternative is i do a seperate sheet for each month, or have one sheet with a drop down of the months and year unsure how to achieve this any ideas?
 
Upvote 0
Yes, you could add more dates to the top, but you would need to manually change the formulas to include those new cells. I would create a sheet for every month with the students name in Column A starting at A2, then in Row1 starting at B1 put the dates for the month, once you have all that information you can then use the previous formulas to calculate attendance for a single day and you could also calculate every individual student's attendance for the whole month. I think that would be the cleanest way to do it.
 
Upvote 0

Forum statistics

Threads
1,216,085
Messages
6,128,732
Members
449,465
Latest member
TAKLAM

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top