SUM Work Hours Between Two Dates

Status
Not open for further replies.

bruntonomo

Board Regular
Joined
Jul 29, 2018
Messages
67
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
I want to find how many hours each employee works between 7/3/2020 and 10/1/2020. This ExcelJet tutorial seems to show how to do what I'm trying to do. However, I can't seem to get it to work. I don't need it to figure out holidays. Our work week is an odd one as it runs Friday - Thursday. Attached is a spreadsheet of the hours each person works each day of each week. Can anyone adapt the formula so that it works?

Below is the formula the link gives:

Code:
=SUMPRODUCT(MID(D6,WEEKDAY(ROW(INDIRECT(B6&":"&C6))),1)*ISNA(MATCH(ROW(INDIRECT(B6&":"&C6)),holidays,0)))
 

Attachments

  • WorkHours.png
    WorkHours.png
    23.8 KB · Views: 19

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
You have weekly totals, you are looking at virtually 13 weeks. Is every week on a separate sheet, in the same format; i.e. Column I will always have weekly totals?
 
Upvote 0
It appears that this is also posted here:

Here is a version that eliminates the helper rows:
Book1_20200606.xlsx
ABCDEFGHIJ
1From -->7/3/202010/1/2020<-- To
2FriSatSunMonTueWedThuWeekly TotalTotal hrs
3name10710863640520
4name210383012844572
5name301161811037481
6name4654859441533
7name5467084130390
8name6021111271144572
9name7411121209149637
10name8471071112455715
11name963201201134442
12name100128800129377
13name118779102144572
14name120400117325325
Sheet3
Cell Formulas
RangeFormula
I3:I14I3=SUM(B3:H3)
J3:J14J3=SUMPRODUCT(INT((WEEKDAY($B$1-{6,7,1,2,3,4,5})-$B$1+$C$1)/7),$B3:$H3)
 
Upvote 0
Please do not post the same question multiple times. All clarifications, follow-ups, and bumps should be posted back to the original thread.
Per forum rules, posts of a duplicate nature will be locked or deleted (rule 12 here: Forum Rules).
 
Upvote 0
Status
Not open for further replies.

Forum statistics

Threads
1,214,985
Messages
6,122,602
Members
449,089
Latest member
Motoracer88

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