• 547K Members
• 2,912 Online
• 652K Conversations

how to count the number of ranges that are seperated by at least one empty cel

Highlighted
Occasional Visitor

how to count the number of ranges that are seperated by at least one empty cel

i would like to count the number of ranges that are filled with data. In this example the outcome should be that row one has two ranges filed with data. Row 2 as well and row three has three ranges filled with data. This is for a spreadsheet where i want to count the frequency a person has called in sick. In the real example i have all the days of the month as columns and in the first column the names. So in this example in this week person one has called in sick on monday, stayed sick for three day, came to work on thursday and called in sick again on friday. The frequency of person 1 calling in sick is 2. That is the number i want

 Monday Tuesday Wednesday thurs fri person 1 1 1 1 1 person 2 1 1 1 person 3 1 1 1

Highlighted

Re: how to count the number of ranges that are seperated by at least one empty cel

Hi Stefan,

That could be

`=SUMPRODUCT((NOT(ISBLANK(B2:K2))*ISBLANK(OFFSET(B2:K2,0,-1))))+NOT(ISBLANK(B2))`

Related Conversations
Counting Days
Tim Hunter in SQL Server on
2 Replies
How to count multiple values in a cell
Ugarte335 in Excel on
7 Replies
A problem with the Zoom level of a Tab
Tavory in Discussions on
9 Replies
Count until
MBelshaw in Excel on
1 Replies
Pivot table
gabriellerocha in Excel on
5 Replies