countif multiple criteria

kylefoley76

Well-known Member
Joined
Mar 1, 2010
Messages
1,553
I want to use a countif formula with multiple criteria. What I want to do is count how many times the cells are <>"" so long as b85 = time!$c$2:$c$5000

This is what I'm thinking but I don't know how to use multiple criteria

=COUNTIF(time!$G$2:$G$5000,time!$H$2:$H$5000<>""&b85=time!$c$2:$c$5000)
 

Excel Facts

Enter current date or time
Ctrl+: enters current time. Ctrl+; enters current date. Use Ctrl+: Ctrl+; Enter for current date & time.
Maybe:

=SUMPRODUCT(--(time!$H$2:$H$5000<>""),--(time!$C$2:$C$5000=B85))

I'm not sure what you want to do with column G.
 
Upvote 0
If you're using Excel 2007 or later, you should use COUNTIFS, which is purpose-built to do exactly what you're trying to do.

Also, it seems to me from your formula, that you might want to use an absolute reference: time!$B$85.
 
Upvote 0
Code:
=COUNTIFS(time!$C$2:$C$5000,B80,time!$J$2:$J$5000,time!$J$2:$J$5000<>"")

Ok, I tried the countifs but it isn't working.

I have two criteria, one b80 must equal the c column in time!

then my second criteria column j <>""

if both those are true then i want to count how many times column j is <>""

So far I'm not getting an error message but i'm also getting zero and i shouldn't
 
Upvote 0

Forum statistics

Threads
1,214,826
Messages
6,121,794
Members
449,048
Latest member
greyangel23

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.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

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

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

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
Back
Top