COUNTIFS with blank cells

NJS1982

Board Regular
Joined
Sep 24, 2009
Messages
183
Office Version
  1. 365
Platform
  1. Windows
Hi, I have a formula which works well to count everything but cells with 'Paid' in them:

=IF(A5="","",COUNTIFS('Payment Tracker'!A:A,A5,'Payment Tracker'!L:L,"<>*Paid*"))

However, I want to also exclude from the count cells which are blank, so I tried this:

=IF(A5="","",COUNTIFS('Payment Tracker'!A:A,A5,'Payment Tracker'!L:L,"<>*Paid*")+COUNTIFS('Payment Tracker'!A:A,A5,'Payment Tracker'!L:L,"<>"))

It does not seem to be excluding the blank cells; does anyone know why this is or how I can fix it?

Thanks!
 

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney
How about this:

Code:
=IF(A5="","",COUNTIFS('Payment Tracker'!A:A,A5,'Payment Tracker'!L:L,"<>*Paid*",'Payment Tracker'!L:L,"<>"))

WBD
 
Upvote 0
Actually...one more tweak, if possible...
If column L:L is quite fluid, is there a way to use a MATCH formula to look through the 'Payment Tracker' sheet and find the 'Status' column (typically, column L, but not always I am finding!)?

A bit like this...

=IF(A5="","",COUNTIFS('Payment Tracker'!A:A,A5,MATCH("Status",'Payment Tracker'!$A$1:$EA$1,0),"<>*Paid*",MATCH("Status",'Payment Tracker'!$A$1:$EA$1,0),"<>"))
 
Last edited:
Upvote 0
Try...
Rich (BB code):
=IF(A5="","",
    COUNTIFS('Payment Tracker'!A:A,A5,
      INDEX('Payment Tracker'!A:XFD,0,MATCH("status",INDEX('Payment Tracker'!A:XFD,1,0),0)),"<>*Paid*",
      INDEX('Payment Tracker'!A:XFD,0,MATCH("status",INDEX('Payment Tracker'!A:XFD,1,0),0)),"<>"))
 
Upvote 0

Forum statistics

Threads
1,216,124
Messages
6,128,995
Members
449,480
Latest member
yesitisasport

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