IF statement for consecutive cells

cloughie

New Member
Joined
Feb 6, 2018
Messages
11
Hi I'm trying to write an IF statement that will tell me if 3 consecutive zero's appear in the row of another worksheet. I also need the statement to tell me if there are more than 3 as well.
 

Excel Facts

Select all contiguous cells
Pressing Ctrl+* (asterisk) will select the "current region" - all contiguous cells in all directions.
This seems to work, play around with some test data to be sure.
Put the data in A1:H1

=COUNTIFS(A1:H1,0,B1:I1,0,C1:J1,0)

If the result equals 1 then there are 3 consecutive zeroes.
If the result equals 2 or more then there are more than 3 consecutive zeroes.
 
Last edited:
Upvote 0
Thanks for this, I should have been a little clearer though.

I have 3 sheets, the first has raw data. The second is using a countifs with wildcards formula to pull the information I need. The third sheet needs to pull the information from the 2nd sheet but needs to identify consecutive zero's up to a specified date range. With any consecutive zero's after this point returning either a text value or a blank cell.
 
Upvote 0

Forum statistics

Threads
1,223,895
Messages
6,175,257
Members
452,625
Latest member
saadat28

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