Using COUNTA horizontally

Dsheaff

New Member
Joined
Aug 14, 2018
Messages
33

I need a formula that will count the number of times the value "N" appears in cell B10 and E10....if "N" does not appear in either cell, the recipient cell (cell G10) is to remain blank


[TABLE="width: 461"]
<colgroup><col width="6" style="width: 5pt; mso-width-source: userset; mso-width-alt: 219;"> <col width="64" style="width: 48pt;"> <col width="6" style="width: 5pt; mso-width-source: userset; mso-width-alt: 219;"> <col width="64" style="width: 48pt;"> <col width="6" style="width: 5pt; mso-width-source: userset; mso-width-alt: 219;"> <col width="64" style="width: 48pt;"> <col width="6" style="width: 5pt; mso-width-source: userset; mso-width-alt: 219;"> <col width="10" style="width: 8pt; mso-width-source: userset; mso-width-alt: 365;"> <col width="6" style="width: 5pt; mso-width-source: userset; mso-width-alt: 219;"> <col width="64" style="width: 48pt;"> <col width="6" style="width: 5pt; mso-width-source: userset; mso-width-alt: 219;"> <col width="64" style="width: 48pt;"> <col width="6" style="width: 5pt; mso-width-source: userset; mso-width-alt: 219;"> <col width="64" style="width: 48pt;"> <col width="6" style="width: 5pt; mso-width-source: userset; mso-width-alt: 219;"> <col width="10" style="width: 8pt; mso-width-source: userset; mso-width-alt: 365;"> <col width="52" style="width: 39pt; mso-width-source: userset; mso-width-alt: 1901;"> <col width="40" style="width: 30pt; mso-width-source: userset; mso-width-alt: 1462;"> <col width="64" style="width: 48pt;"> <tbody>[TR]
[TD="width: 6, bgcolor: transparent"] [/TD]
[TD="width: 204, bgcolor: transparent, colspan: 5"]Tree Trimming Requirement Met
[/TD]
[TD="width: 6, bgcolor: transparent"] [/TD]
[TD="width: 10, bgcolor: transparent"][/TD]
[TD="width: 6, bgcolor: transparent"] [/TD]
[TD="width: 204, bgcolor: transparent, colspan: 5"]Mowing Requirement Met[/TD]
[TD="width: 6, bgcolor: transparent"] [/TD]
[TD="width: 10, bgcolor: transparent"][/TD]
[TD="width: 52, bgcolor: transparent"][/TD]
[TD="width: 40, bgcolor: transparent"][/TD]
[TD="width: 64, bgcolor: transparent"][/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"] A
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"] B
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"] C
[/TD]
[TD="bgcolor: transparent"] D
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"] E
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"] F
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"]G[/TD]
[TD="bgcolor: transparent"][/TD]

[/TR]
[TR]
[TD="bgcolor: transparent"]Yes
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"]No
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"]CEAP *
[/TD]
[TD="bgcolor: transparent"]Yes[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"]No[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"]CEAP *[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="width: 156, bgcolor: transparent, colspan: 3"]Number of Times Requirement Not Met[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"](Y)
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"](N)
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"](X)[/TD]
[TD="bgcolor: transparent"](Y)[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"](N)[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"](X)[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"]N
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"]N
[/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"][/TD]
[TD="bgcolor: transparent"]
[/TD]
[TD="bgcolor: transparent"][/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!
Welcome to the Board!

One way:
Code:
=IF((E10="N")+(G10="N")>0,(E10="N")+(G10="N"),"")
 
Upvote 0
Hi,

Joe4 had a typo in his formula (fixed in G10), and I included another way to write it (H10), just in case you meant to count the range B10:E10, use I10


Book1
BCDEFGHI
10NXYN222
Sheet180
Cell Formulas
RangeFormula
G10=IF((B10="N")+(E10="N"),(B10="N")+(E10="N"),"")
H10=IF(OR(B10="N",E10="N"),(B10="N")+(E10="N"),"")
I10=IF(COUNTIF(B10:E10,"N"),COUNTIF(B10:E10,"N"),"")
 
Last edited:
Upvote 0
Joe4 had a typo in his formula (fixed in G10), and I included another way to write it (H10), just in case you meant to count the range B10:E10, use I10
Good catch.
Thank you.
 
Upvote 0

Forum statistics

Threads
1,223,970
Messages
6,175,703
Members
452,667
Latest member
vanessavalentino83

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