Counting Max consecutive days worked

MDuff

Well-known Member
Joined
Dec 29, 2002
Messages
529
Office Version
  1. 365
Platform
  1. Windows
Hi I have a list of Days worked what I need a formula that will tell me how many max days they worked without having a day off So only courting the 1 on the example before 1 is a day worked blank is a day off.

Please see sheet layout below

Thanks in advance
Excel Workbook
BCDEFGHIJKLM
5MonTueThrFriSatSunMonTueThrFriSatSun
6111111111
711111111
8111111111
911111111
1011111111
1111111111
1211111111
Sheet4
Excel 2007
 

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.
Sorry first screen shot was missing monday here it is updated
Excel Workbook
BCDEFGHIJKLM
5MonTueWedThrFriSatSunMonTueWedThrFri
611111111
7111111111
811111111
911111111
10111111111
111111111111
12111111111
1311111111
1411111111
Sheet4
Excel 2007
 
Upvote 0
What is desired?

thanks for the reponce :) but...

Sorry Aladin not sure what exactly you mean by Desired? what I am looking for is to count the max number of days (1) that are consecutive acoross the row
 
Upvote 0
For Row 6... is the count you want 5 or 7 (in other words, do we ignore weekends or not)?
 
Upvote 0
thanks for the reponce :) but...

Sorry Aladin not sure what exactly you mean by Desired? what I am looking for is to count the max number of days (1) that are consecutive acoross the row

Care to state the desired result per row (record) for the sample you posted?
 
Upvote 0
hope this helps

the result in this example would be 8 and yes I want to include weekend
Excel Workbook
DEFGHIJKLMNOP
53111111111
Sheet4
Excel 2007
 
Upvote 0
hope this helps

the result in this example would be 8 and yes I want to include weekend
Excel Workbook
DEFGHIJKLMNOP
53111111111
Sheet4
Excel 2007
Q6, control+shift+enter, not just enter, and copy down:

=MAX(FREQUENCY(IF(B6:M6=1,COLUMN(B6:M6)),IF(B6:M6<>1,COLUMN(B6:M6))))
 
Upvote 0

Forum statistics

Threads
1,224,560
Messages
6,179,519
Members
452,921
Latest member
BBQKING

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