Right to left counting cells with value until the first empty cell

benntw

Board Regular
Joined
Feb 17, 2014
Messages
146
I'm looking to count from right to left counting the number of cells with a value until the first empty cell. All cells are formulas. The range is set D:Y. I need to count cells that are greater than 0 until it reaches an empty cell. Can someone help me out with this ?
 

mikerickson

MrExcel MVP
Joined
Jan 15, 2007
Messages
22,897
It sounds like "consider the cells between column Y and the first empty cell to the left of that, what number of those cells contain a value > 0"

If that is the question then
=COUNTIF(INDEX(1:1,1,MAX(IF(A1:Y1="",COLUMN(A1:Y1)))):Y1, ">0")
entered with Ctrl-Shift-Enter should do what you want.
 

benntw

Board Regular
Joined
Feb 17, 2014
Messages
146
My date range is D4:Y4. I have a list of names in column A and a id number in column b. Column C has no value and their days they worked start in column D to Y. I am working backwards from current date to make sure their count of days worked does not exceed 13 straight. I tried the above formula and I am getting a value error. All the cells are populated with a sumif formula on a table if that makes any difference to the formula above.
 

Forum statistics

Threads
1,086,093
Messages
5,387,793
Members
402,076
Latest member
MotoMoto

Some videos you may like

This Week's Hot Topics

Top