# Countif or SumProduct?

#### rogersj

##### Board Regular
I have a bunch of data (text) in D. I want to know how many strings there are... I tried

=COUNTIF(D4:D160,<"")

But can't get it to work. What's the proper formula? Thanks.

### Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
Perhaps:
=COUNTIF(D4:D160,<>"")

Just to be clear, what do you mean by "how many strings"?

This will help achieve your desired result.

Michael

can't you also throw a ISTEXT() in there

I have items listed all throughout D4-D160, I want to count if there is anything in each cell.

In that case:
=COUNTA(D4:D160)

Replies
2
Views
178
Replies
3
Views
266
Replies
4
Views
626
Replies
3
Views
134
Replies
12
Views
372

1,221,153
Messages
6,158,237
Members
451,477
Latest member
CWebbers

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back