Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 13
Default Countif with parameters from another range?

I need to count the instances on the word "Trane" in a range of cells, but
base the countif statement on the information in another range of cells. If
the parameter range has a "N" in it, then count the corresponding cell in the
counting range with "Trane" in it. If not, don't count it. This needs to be
a formula entered in one cell that displays the results of the countif. I
have tried this formula:
=COUNT(IF(($A$2:$A$297="N")*($O$2:$O$297="Trane"), $O$2:$O$297))
that is shown in the help section, but it only returns zeros when I use it.
Any help would be greatly appreciated!
-Kai
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,202
Default Countif with parameters from another range?

I need to count the instances on the word "Trane" in a range of cells, but
base the countif statement on the information in another range of cells.
If
the parameter range has a "N" in it, then count the corresponding cell in
the
counting range with "Trane" in it. If not, don't count it. This needs to
be
a formula entered in one cell that displays the results of the countif. I
have tried this formula:
=COUNT(IF(($A$2:$A$297="N")*($O$2:$O$297="Trane"), $O$2:$O$297))
that is shown in the help section, but it only returns zeros when I use
it.
Any help would be greatly appreciated!


Give this formula a try...

=SUMPRODUCT(--($A$2:$A$297="N"),--($O$2:$O$297="Trane"))

Rick

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,939
Default Countif with parameters from another range?

You can do it with SumProduct... check out this link.

http://www.xldynamic.com/source/xld.SUMPRODUCT.html
--
HTH...

Jim Thomlinson


"Kai Cunningham" wrote:

I need to count the instances on the word "Trane" in a range of cells, but
base the countif statement on the information in another range of cells. If
the parameter range has a "N" in it, then count the corresponding cell in the
counting range with "Trane" in it. If not, don't count it. This needs to be
a formula entered in one cell that displays the results of the countif. I
have tried this formula:
=COUNT(IF(($A$2:$A$297="N")*($O$2:$O$297="Trane"), $O$2:$O$297))
that is shown in the help section, but it only returns zeros when I use it.
Any help would be greatly appreciated!
-Kai

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 857
Default Countif with parameters from another range?

Kai,

Here's one way:

=SUMPRODUCT(($A$2:$A$297="N")*($O$2:$O$297="Trane" ))


--
Hope that helps.

Vergel Adriano


"Kai Cunningham" wrote:

I need to count the instances on the word "Trane" in a range of cells, but
base the countif statement on the information in another range of cells. If
the parameter range has a "N" in it, then count the corresponding cell in the
counting range with "Trane" in it. If not, don't count it. This needs to be
a formula entered in one cell that displays the results of the countif. I
have tried this formula:
=COUNT(IF(($A$2:$A$297="N")*($O$2:$O$297="Trane"), $O$2:$O$297))
that is shown in the help section, but it only returns zeros when I use it.
Any help would be greatly appreciated!
-Kai

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 13
Default Countif with parameters from another range?

Thanks a ton for the quick responses! Worked like a charm!
-Kai

"Vergel Adriano" wrote:

Kai,

Here's one way:

=SUMPRODUCT(($A$2:$A$297="N")*($O$2:$O$297="Trane" ))


--
Hope that helps.

Vergel Adriano


"Kai Cunningham" wrote:

I need to count the instances on the word "Trane" in a range of cells, but
base the countif statement on the information in another range of cells. If
the parameter range has a "N" in it, then count the corresponding cell in the
counting range with "Trane" in it. If not, don't count it. This needs to be
a formula entered in one cell that displays the results of the countif. I
have tried this formula:
=COUNT(IF(($A$2:$A$297="N")*($O$2:$O$297="Trane"), $O$2:$O$297))
that is shown in the help section, but it only returns zeros when I use it.
Any help would be greatly appreciated!
-Kai

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
Conditional Sum without Range Parameters Peige414 Excel Worksheet Functions 5 October 22nd 08 05:55 PM
Range Parameters Bertrand Excel Programming 1 July 21st 06 04:26 PM
Range Parameters in Function [email protected] Excel Programming 1 February 3rd 06 03:11 AM
countif - I want to enter 2 parameters - how? NancyP192 Excel Programming 2 February 2nd 06 05:43 PM
Count cells in one range based on parameters in another range dave roth Excel Worksheet Functions 2 March 29th 05 05:33 PM


All times are GMT +1. The time now is 08:59 AM.

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

About Us

"It's about Microsoft Excel"