Use COUNTIF on a non-contiguous range in Excel
This step-by-step guide demonstrates how to use the countif function on a non-contiguous range in Excel. Supposing there are three non-contiguous ranges B5:B12, D5:D13 and F7:F11 in your worksheet, to count number of cells that are greater than 80 in these specified ranges, you can use the COUNTIF function together with the INDIRECT and SUM functions to get it done.
How to use COUNTIF on a non-contiguous range in Excel?
Before using the COUNTIF function for non-contiguous range, let’s know what a non-contiguous range is. A non-contiguous range consists of many separate ranges in a worksheet, such as the ranges B5:B12, D5:D13 and F7:F11 as the below screenshot shown.
To count number of cells that are greater than 80 in this non-contiguous range, please apply the below formula.
Rng1: The first range of the non-contiguous range.
Rng2: The second range of the non-contiguous range.
Rng3: The third range of the non-contiguous range.
Criteria: The criteria you want to count cells based on.
How to use these formulas?
1. Select a blank cell.
2. Enter the below formula into it and press the Enter key to get the result.
Notes:: In the formula, you can change the ranges and criteria based on your needs.
Excel SUM function
The Excel SUM function adds values.
Excel COUNTIF function
The Excel COUNTIF function is used to count the number of cells that meet a criterion.
Excel INDIRECT function
The Excel INDIRECT function converts a text string to a valid reference.
The Best Office Productivity Tools
Would you like to complete your daily work quickly and perfectly? Kutools for Excel brings
300 powerful advanced features (Combine workbooks, sum by color, split cell contents, convert date, and so on...) and save
80% time for you.
- Designed for
1500 work scenarios, helps you solve
80% Excel problems.
- Reduce thousands of keyboard and mouse clicks every day, relieve your tired eyes and hands.
- Become an Excel expert in 3 minutes. No longer need to remember any painful formulas and VBA codes.
30-day unlimited free trial. 60-day money back guarantee. Free upgrade and support for 2 years.
- One second to switch between dozens of open documents!
- Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
- Increases your productivity by
50% when viewing and editing multiple documents.
- Brings Efficient Tabs to Office (include Excel), Just Like Chrome, Firefox, And New Internet Explorer.