How do I count cells with text but ignore cells with spaces?

G

Guest

I have a form that users enter names in a column and I need to count them.
Unfortunately some users simple hit the space bar to “delete†a name instead
of using the clear or delete key. In those cells, with spaces now which
appear to be blank, the cell is treated like it has text in it when I use the
counting functions. Any suggestions on how I count the names only and ignore
the cells that are blank and the cells with just a couple of spaces in them?

What do you think? Thanks.
 
B

Biff

What do you think?

I think you should cut your users fingers off! <g>

Try this:

=SUMPRODUCT(--(LEN(TRIM(A1:A10))>0))

Biff
 
G

Guest

Use the Filter tool, that will get rid of all the blank cells. You can copy
the total document into another worksheet and use the count function and get
your total.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top