Forum Discussion

galgocarp's avatar
galgocarp
Copper Contributor
Jan 02, 2023
Solved

How to count cells based on date and if not empty

If anyone could help me I have an excel spreadsheet where the top row are dates and the first column has different tasks. Below each date there is data to mark if something was done or not on each day. What I want to do is to count the days for each task that is not empty but that happened before today (there are dates in the future that already have some inputs that work as reminders and I don't need those to be counted).

 

For example, in the table below, if i use the COUNTA formula it will count all cells that are not empty, even if the date is after today. For Task 1 the count should be 3, given that 3 actions were taken today or before, but with the COUNTA formula it returns 4, as it counts the cell value on 3-JAN, which I do not need to be counted. For TASK 2 it should be 2 but its 4 with COUNTA, and so on.

 

Resources