Good morning,

A have a worksheet with many columns of data. In each column, some of the cells contain entries, but some are blank. I'm looking to count the number of cells which contain entries including the blank cells along the way, but not beyond the last cell with an entry in it. Currently I'm using the formula below:

=(COUNTA(M7:M))+(COUNTBLANK(M7:M118))

The inconvenience being that the data is on a Google Sheet, and new entries regularly come in as the data is on an IMPORTRANGE function. So, I regularly have to log in and adjust the COUNTBLANK range for each column to ensure any blanks are counted, but I can't just put the COUNTBLANK all the way to the bottom because if would count the empty cells forever.

My query is, is it possible to write a formula that would count all the cells (blanks included) right down to the last cell with an entry in it, preferably one I don't have to manually adjust so often?

Many thanks for your help, and please let me know if I can provide any more information.

Dave