#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
play01
 
Posts: n/a
Default countif


=AND(COUNTIF(A1:A5,"HM"))*(COUNTIF(B1:B5,"5"))
Trying to calculate the following:
A B
1 HM 5
2 HM 2
3 HM 4
4 HG 5
5 HM 5

Count the number of times "HM" is in column A and "5" is in column B.

Thanks for the help.
Todd


--
play01
------------------------------------------------------------------------
play01's Profile: http://www.excelforum.com/member.php...o&userid=32635
View this thread: http://www.excelforum.com/showthread...hreadid=524432

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Trevor Shuttleworth
 
Posts: n/a
Default countif

Todd

=SUMPRODUCT((A1:A5="HM")*(B1:B5=5))

Regards

Trevor


"play01" wrote in
message ...

=AND(COUNTIF(A1:A5,"HM"))*(COUNTIF(B1:B5,"5"))
Trying to calculate the following:
A B
1 HM 5
2 HM 2
3 HM 4
4 HG 5
5 HM 5

Count the number of times "HM" is in column A and "5" is in column B.

Thanks for the help.
Todd


--
play01
------------------------------------------------------------------------
play01's Profile:
http://www.excelforum.com/member.php...o&userid=32635
View this thread: http://www.excelforum.com/showthread...hreadid=524432



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
daddylonglegs
 
Posts: n/a
Default countif


Try this

=SUMPRODUCT(--(A1:A5="HM"),--(B1:B5=5))

If the 5 is text not numeric then use "5" instead


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile: http://www.excelforum.com/member.php...o&userid=30486
View this thread: http://www.excelforum.com/showthread...hreadid=524432

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Countif Formula /Sort Bug??? orcfodder Excel Discussion (Misc queries) 2 January 12th 06 10:04 AM
Countif, then multiply?? Gee-off Excel Worksheet Functions 4 December 7th 05 08:55 PM
COUNTIF or not to COUNTIF on a range in another sheet Ellie Excel Worksheet Functions 4 September 15th 05 10:06 PM
Combining IF and COUNTIF based on two columns maxtrixx Excel Discussion (Misc queries) 5 March 31st 05 06:21 PM
Countif - Countif maswinney Excel Worksheet Functions 3 November 15th 04 11:06 PM


All times are GMT +1. The time now is 02:52 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"