Forum Discussion
Saurabh Khanna
Mar 18, 2018Copper Contributor
Count number of blank cells till last non empty cell in a column.
 Hello - 
   
 I want to count number of blank cells till last non empty cell in a column but could not figure out how to do this, can you please help? 
   
 When I use Countblank formula, it takes an...
- Mar 20, 2018It does not work because of circular reference problem.
My formula range starts from A1 while you also want to use inside the same range.
To make this work you need to redefjne the starting row of your column A in the formula for example if your start of data starts from A4 then the modified formula should be
=COUNTBLANK(A$4:INDEX(A:A,SUMPRODUCT(MAX((A:A<>"")*ROW(A:A)))))
This should work. 
SergeiBaklan
Dec 05, 2018Diamond Contributor
Or
=IFNA(COUNTBLANK(A3:INDEX(A:A,LOOKUP(2,1/(A:A<>""),ROW(A:A)))),0)
(regular formula)
Saurabh Khanna
Dec 05, 2018Copper Contributor
Hello -
When I downloaded your file, I am not getting result, it shows error.
I have taken screenshot "1" when file is downloaded and opened, and "2" when I pasted the formula in the cell.
Am i doing something wrong at me end, or is it Excel version compatibility issue; I am using Excel 2010?
Thank You,
Saurabh Khanna.
- Saurabh KhannaDec 07, 2018Copper ContributorMany Thanks Sergei for your help, it works great.
 - SergeiBaklanDec 05, 2018Diamond Contributor
You may change IFNA on IFERROR