Formula help , countifs, conditional formatting

mariearcus

New Member
Joined
Dec 8, 2015
Messages
13
This is a long shot but I'm hoping someone can help and that the calculation I'm trying to make can run in excel.

In brief, I work in HR and we need to create a new way to calculate holiday pay using extracted data (into excel) from our payroll system.

Holiday pay for 200 of our employees needs to be worked out by adding up the last 12 weeks or normal pay and dividing by 12. The issue is there are exceptions such as when the employee takes a day holiday, sick or attends college then we have to exclude that week and go back to week 13 et c....

So far I've just added conditional formatting to highlight which weeks should be included in the average 12 weeks calculation. My issue is how to create a formula to add up JUST the 12 weeks which should be included?

The spreadsheet is setup like this...

Column A - employee name
B - basic pay £
C - price work £
D - holiday pay £
E - sick pay £
F - college pay£
G - include/exclude

The spreadsheet includes pay data going back 20 weeks, but could be more or less depending on how we extract the data.

Each week I will need to download the data from our weekly payroll system and add to the spreadsheet so whatever formula I use needs to work like this.
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
Thanks for your continued effort to post the data, I am sorry this has been so dramatic, I'm not a big believer that seeking help should be so complicated.

I got the data you posted above and have separated in the a table, so the next questions are, what do the columns mean and what do you need to do with the data... sorry, still a little fuzzy to comprehend your payroll process.

from the data you posted this is what I gather, the exclude I imagine is for the weeks that don't count, then what needs to be done again?

thanks



Sheet1

ABCDEFGHIJKLMNOP
emp nameweekyear
WnameBexclude
WnameBinclude
WnameBinclude
WnameBinclude
WnameBexclude
WnameBinclude
WnameBinclude
WnameBinclude
WnameBinclude
WnameBinclude
WnameBinclude
WnameBinclude
WnameBinclude
WnameBexclude
WnameBexclude
WnameBinclude
WnameBinclude

<colgroup><col style="font-weight:bold; width:30px; "><col style="width:73px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"><col style="width:64px;"></colgroup><tbody>
[TD="bgcolor: #cacaca, align: center"]1[/TD]

[TD="bgcolor: #cacaca, align: center"]2[/TD]

[TD="align: right"]19[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]402.92[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]402.92[/TD]
[TD="align: right"]100.73[/TD]
[TD="align: right"]8.5[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]109.23[/TD]

[TD="bgcolor: #cacaca, align: center"]3[/TD]

[TD="align: right"]20[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]4[/TD]

[TD="align: right"]21[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]5[/TD]

[TD="align: right"]22[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]6[/TD]

[TD="align: right"]23[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]435.4[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]435.4[/TD]
[TD="align: right"]105.74[/TD]
[TD="align: right"]8.5[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]114.24[/TD]

[TD="bgcolor: #cacaca, align: center"]7[/TD]

[TD="align: right"]24[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]8[/TD]

[TD="align: right"]25[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]9[/TD]

[TD="align: right"]26[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]10[/TD]

[TD="align: right"]27[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]11[/TD]

[TD="align: right"]28[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]12[/TD]

[TD="align: right"]29[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]566.02[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]566.02[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]13[/TD]

[TD="align: right"]30[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]14[/TD]

[TD="align: right"]31[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]15[/TD]

[TD="align: right"]32[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]42.5[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]571.2[/TD]

[TD="bgcolor: #cacaca, align: center"]16[/TD]

[TD="align: right"]33[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]422.96[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]422.96[/TD]
[TD="align: right"]105.74[/TD]
[TD="align: right"]8.5[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]114.24[/TD]

[TD="bgcolor: #cacaca, align: center"]17[/TD]

[TD="align: right"]34[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

[TD="bgcolor: #cacaca, align: center"]18[/TD]

[TD="align: right"]35[/TD]
[TD="align: right"]2015[/TD]
[TD="align: right"]547.36[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]547.36[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]

</tbody>


Excel Tabellen im Web darstellen >> Excel Jeanie HTML 4.8
 
Upvote 0
Yes, that's great.
Now, what happens if there are more or there are less than 12 weeks shown to be included for an employee?


I have pasted more than 12 weeks data as the problem is when an employee takes a day off on holiday/sick or at college then we cannot include that week in the 12 week average. Therefore we would need to go back a further week or weeks to get an average 12 weeks of 'normal' work... I think this is where the formula could prove tricky. The 12 week reference period is the 12 weeks preceding the week they want to take as holiday (unless of the aforementioned scenario).

Basically I need to create a formula to add up 12 weeks of 'normal' pay each week (so it needs to understand to exclude those week where the employee is sick/training/on holiday). Then I can just divide that figure by 12. It's adding up the correct 12 weeks which I'm struggling with.

Also, each week I will be downloading another week of payroll info, so will need to run this report weekly.

Apologies if I'm not explaining this well !

https://www.nibusinessinfo.co.uk/content/calculating-and-paying-holiday-pay
 
Upvote 0
I asked because your table shows:

WnameB, 13 weeks, include
WnameA, 10 weeks, include
WnameC, 12 weeks, include

Should the formula be always dividing by 12, assuming you'll make adjustments weekly?

Here's what I have so far:


Excel 2010
ABCDEFGHIJKLMNOP
1Include in 12 week average holiday payExclude from 12 week average holiday pay
2EmployeePd. YrBasic Hours (pd. amount)Price Work (pd. amount)Time+Half (pd. amount)Double Time (pd. amount)Bonus (pd. amount)Total 'Normal' Pay to be includedHoliday Pay (pd. amount)Holiday Pay Hours (input amount)College Hours (pd. amount)Co.Sick Pay (pd. amount)SSP (pd. amount)Total - these weeks to be excludedInclude or Exclude in Holiday Pay AverageHoliday Pay (weekly rate) 12 week average of 'Normal' pay
3WnameB19 2015402.920000402.92100.738.5000109.23exclude$587.79
4WnameB20 2015553.580000553.58000000include
5WnameB21 2015541.140000541.14000000include
6WnameB22 2015553.580000553.58000000include
7WnameB23 2015435.40000435.4105.748.5000114.24exclude
8WnameB24 2015541.140000541.14000000include
9WnameB25 2015528.70000528.7000000include
10WnameB26 2015553.580000553.58000000include
11WnameB27 2015528.70000528.7000000include
12WnameB28 2015541.140000541.14000000include
13WnameB29 2015566.020000566.02000000include
14WnameB30 2015528.70000528.7000000include
15WnameB31 2015528.70000528.7000000include
16WnameB32 2015000000528.742.5000571.2exclude
17WnameB33 2015422.960000422.96105.748.5000114.24exclude
18WnameB34 2015541.140000541.14000000include
19WnameB35 2015547.360000547.36000000include
20WnameA19 2015000000000512.130512.13exclude$627.88
21WnameA20 2015000000000512.130512.13exclude
22WnameA21 2015000000000512.130512.13exclude
23WnameA22 201551.21000051.21000409.717.69427.39exclude
24WnameA23 2015000000102.438.50070.76181.69exclude
25WnameA24 20150850000850000000include
26WnameA25 20150800000800000000include
27WnameA26 20150817000817000000include
28WnameA27 20150900000900102.438.5000110.93exclude
29WnameA28 20150731000731000000include
30WnameA29 20150600000600000000include
31WnameA30 20150348000348204.8517000221.85exclude
32WnameA31 20150607000607000000include
33WnameA32 20150689000689000000include
34WnameA33 20150839000839000000include
35WnameA34 20150851.5000851.5000000include
36WnameA35 20150750000750000000include
37WnameC19 2015276.250000276.25000000include$309.90
38WnameC20 2015318.750000318.75000000include
39WnameC21 201563.75000063.7525534000289exclude
40WnameC22 20152550000255000000include
41WnameC23 2015255000025563.758.500072.25exclude
42WnameC24 2015318.750000318.75000000include
43WnameC25 2015318.750000318.75000000include
44WnameC26 2015318.750000318.75000000include
45WnameC27 2015318.750000318.75000000include
46WnameC28 2015318.750000318.75000000include
47WnameC29 2015318.750000318.75000000include
48WnameC30 2015318.750000318.75000000include
49WnameC31 2015318.750000318.75000000include
50WnameC32 2015318.750000318.75000000include
Sheet1
Cell Formulas
RangeFormula
P3=SUMIFS(H$3:H$50,A$3:A$50,A3,O$3:O$50,"include")/12
P20=SUMIFS(H$3:H$50,A$3:A$50,A20,O$3:O$50,"include")/12
P37=SUMIFS(H$3:H$50,A$3:A$50,A37,O$3:O$50,"include")/12


For some reason, I could only copy your table upto Pd. Yr 32 2015...
 
Last edited:
Upvote 0
Thank you

I've pasted that in but I think perhaps it needs alteration?

For example, adding up the weeks of pay to be included for holiday taken in week 35, so 12 weeks normal pay upto and including week 34 - means we use the data in H5, H6, H8-H15 and H17, H18. This adds up to £6,375.50 then dividing by 12 gives an answer of £531.29. I'd expect that amount to the result in cell P19.

Does this make sense?

Thanks so much for your help so far
 
Upvote 0
Ok, from your previous post, H17 is excluded so it shouldn't count right?

this is what I have, I added one additional column for calculation:

Sheet1

[TABLE="class: grid, width: 500"]
<tbody>[TR="bgcolor: #cacaca"]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[TD]C[/TD]
[TD]D[/TD]
[TD]E[/TD]
[TD]F[/TD]
[TD]G[/TD]
[TD]H[/TD]
[TD]I[/TD]
[TD]J[/TD]
[TD]K[/TD]
[TD]L[/TD]
[TD]M[/TD]
[TD]N[/TD]
[TD]O[/TD]
[TD]P[/TD]
[TD]Q[/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]2[/TD]
[TD]Employee[/TD]
[TD]Pd. Yr[/TD]
[TD]Basic Hours
(pd. amount)[/TD]
[TD]Price Work
(pd. amount)[/TD]
[TD]Time+Half
(pd. amount)[/TD]
[TD]Double Time
(pd. amount)[/TD]
[TD]Bonus
(pd. amount)[/TD]
[TD]Total 'Normal' Pay to be included[/TD]
[TD]Holiday Pay
(pd. amount)[/TD]
[TD]Holiday Pay Hours
(input amount)[/TD]
[TD]College Hours
(pd. amount)[/TD]
[TD]Co.Sick Pay
(pd. amount)[/TD]
[TD]SSP
(pd. amount)[/TD]
[TD]Total - these weeks to be excluded[/TD]
[TD="align: center"]Include or Exclude in Holiday Pay Average[/TD]
[TD="align: center"]Count[/TD]
[TD="align: center"]Holiday Pay (weekly rate)

12 week average of 'Normal' pay[/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]3[/TD]
[TD]WnameB[/TD]
[TD]19 2015[/TD]
[TD="align: right"]402.92[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]402.92[/TD]
[TD="align: right"]100.73[/TD]
[TD="align: right"]8.5[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]109.23[/TD]
[TD="align: center"]exclude[/TD]
[TD="align: center"]0[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]4[/TD]
[TD]WnameB[/TD]
[TD]20 2015[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]1[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]5[/TD]
[TD]WnameB[/TD]
[TD]21 2015[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]2[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]6[/TD]
[TD]WnameB[/TD]
[TD]22 2015[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]3[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]7[/TD]
[TD]WnameB[/TD]
[TD]23 2015[/TD]
[TD="align: right"]435.4[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]435.4[/TD]
[TD="align: right"]105.74[/TD]
[TD="align: right"]8.5[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]114.24[/TD]
[TD="align: center"]exclude[/TD]
[TD="align: center"]3[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]8[/TD]
[TD]WnameB[/TD]
[TD]24 2015[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]4[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]9[/TD]
[TD]WnameB[/TD]
[TD]25 2015[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]5[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]10[/TD]
[TD]WnameB[/TD]
[TD]26 2015[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]553.58[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]6[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]11[/TD]
[TD]WnameB[/TD]
[TD]27 2015[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]7[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]12[/TD]
[TD]WnameB[/TD]
[TD]28 2015[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]8[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]13[/TD]
[TD]WnameB[/TD]
[TD]29 2015[/TD]
[TD="align: right"]566.02[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]566.02[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]9[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]14[/TD]
[TD]WnameB[/TD]
[TD]30 2015[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]10[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]15[/TD]
[TD]WnameB[/TD]
[TD]31 2015[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]11[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]16[/TD]
[TD]WnameB[/TD]
[TD]32 2015[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]528.7[/TD]
[TD="align: right"]42.5[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]571.2[/TD]
[TD="align: center"]exclude[/TD]
[TD="align: center"]11[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]17[/TD]
[TD]WnameB[/TD]
[TD]33 2015[/TD]
[TD="align: right"]422.96[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]422.96[/TD]
[TD="align: right"]105.74[/TD]
[TD="align: right"]8.5[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]114.24[/TD]
[TD="align: center"]exclude[/TD]
[TD="align: center"]11[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]18[/TD]
[TD]WnameB[/TD]
[TD]34 2015[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]541.14[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]12[/TD]
[TD="align: center"]542.1766667[/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]19[/TD]
[TD]WnameB[/TD]
[TD]35 2015[/TD]
[TD="align: right"]547.36[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]547.36[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: center"]include[/TD]
[TD="align: center"]13[/TD]
[TD="align: center"]542.5753846[/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]20[/TD]
[TD]WnameA[/TD]
[TD]19 2015[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]512.13[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]512.13[/TD]
[TD="align: center"]exclude[/TD]
[TD="align: center"]0[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]21[/TD]
[TD]WnameA[/TD]
[TD]20 2015[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]512.13[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]512.13[/TD]
[TD="align: center"]exclude[/TD]
[TD="align: center"]0[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]22[/TD]
[TD]WnameA[/TD]
[TD]21 2015[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]512.13[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]512.13[/TD]
[TD="align: center"]exclude[/TD]
[TD="align: center"]0[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]23[/TD]
[TD]WnameA[/TD]
[TD]22 2015[/TD]
[TD="align: right"]51.21[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]51.21[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]409.7[/TD]
[TD="align: right"]17.69[/TD]
[TD="align: right"]427.39[/TD]
[TD="align: center"]exclude[/TD]
[TD="align: center"]0[/TD]
[TD][/TD]
[/TR]
[TR]
[TD="bgcolor: #cacaca, align: center"]24[/TD]
[TD]WnameA[/TD]
[TD]23 2015[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]102.43[/TD]
[TD="align: right"]8.5[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]0[/TD]
[TD="align: right"]70.76[/TD]
[TD="align: right"]181.69[/TD]
[TD="align: center"]exclude[/TD]
[TD="align: center"]0[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]

Formula on P3 is =COUNTIFS($A$3:A3,A3,$O$3:O3,"include")
Formula on Q3 is =IF(P3<13,"",AVERAGEIF($O$3:O3,"include",$H$3:H3))

just copy down the formula, I believe this is what you're looking for?

here's the file is you wish to download -> https://drive.google.com/file/d/0B1t6R5UwL0-2d1NqRGNhMm0zTFE/view?usp=sharing

hope we're getting close.

Angel


Thank you

I've pasted that in but I think perhaps it needs alteration?

For example, adding up the weeks of pay to be included for holiday taken in week 35, so 12 weeks normal pay upto and including week 34 - means we use the data in H5, H6, H8-H15 and H17, H18. This adds up to £6,375.50 then dividing by 12 gives an answer of £531.29. I'd expect that amount to the result in cell P19.

Does this make sense?

Thanks so much for your help so far
 
Upvote 0

Forum statistics

Threads
1,223,247
Messages
6,171,007
Members
452,374
Latest member
keccles

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