Countif formula help required

Quinton

Board Regular
Joined
Nov 6, 2008
Messages
125
Hello please help!!

I have the following data (small example with all scenarios):
14-04-14 < empty >
16-12-11 12-12-11
< empty > 12-11-10
< empty > < empty >

Basically either dates or < empty > in either 2 columns.

I would like to count "1" in Column "C" if Column "A" has a date & Column "B" has no date. Otherwise in any other event count "0".

So the results (in column "C") would be as follows for the data above:
1
0
0
0

Many thanks in advance
 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
Many thanks for your help. But this did not work. I applied your formula to my spreadsheet in the following way:

=IF(AND(C8<>"",D8=""),1,0)

C8 & D8 being the actual columns in my sheet.

Any ideas or did I do something wrong.

Angain many thanks!

PS - thought I should mention that < empty > is actually in the cell!
 
Last edited:
Upvote 0
Funny I just edited my previous post saying that the cells are not blank they actually show < empty >.

Hope this helps!

Thanks again
 
Upvote 0
Thanks again, nearly there I think - as it still does not work. It is returning "0" in every case.

I think the problem is that it needs to count "1" if a date exists in column "C" and "< empty >" exists in column "D".

As per my original Post

Sorry hope this helps?

Again many thanks
 
Upvote 0
Whoops - Very sorry ignore last post as it works perfectly!!!!!

Many thanks for your help!!!!

Kind regards

Quinton
 
Upvote 0
Hello again!

Sorry but I am just trying to apply your last formula to another one I am trying to sort out.

I now have the following formula:

=IF(AND(E8<>"< empty ><EMPTY>",C8="< empty ><EMPTY>"),1,0)

I need to apply it to the following data:

Column C Column E
< empty > 09-09-10
< empty > < empty >
14-04-14 < empty >
16-12-11 18-12-11
12-05-11 08-09-10

With the following results being shown:

1
0
0
1

The difference is the following:

Line 4 2nd columns date happens before the 1st column date so it now counts it.

Is this one possible as it is far too complex for my small brain?

Thanks again in advance!!!!
 
Upvote 0
Perhaps

=IF(AND(ISNUMBER(C1),ISNUMBER(E1),C1<E1),1,IF(AND(C1<>"< empty >",E1="< empty >"),1,0))
 
Upvote 0

Forum statistics

Threads
1,224,522
Messages
6,179,297
Members
452,903
Latest member
Knuddeluff

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