#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default Countif Question

How do I get a formula to automatically update to count the number of times a
changing value exists within the same range of cells?

Example:
If my range needs to always be B2:F350, how can I count within that range
how many times the number 1 appears, then 2, then 3, etc.

I have COUNTIF($B$2:$F$350,"=1") but I don't want to have to change the
number every time. I want to copy down so the 1 automatically changes to 2
then 3...

Thanks!
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,718
Default Countif Question

COUNTIF($B$2:$F$350,ROW(A1))


"b4nature" wrote:

How do I get a formula to automatically update to count the number of times a
changing value exists within the same range of cells?

Example:
If my range needs to always be B2:F350, how can I count within that range
how many times the number 1 appears, then 2, then 3, etc.

I have COUNTIF($B$2:$F$350,"=1") but I don't want to have to change the
number every time. I want to copy down so the 1 automatically changes to 2
then 3...

Thanks!

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,240
Default Countif Question

b4nature wrote:
How do I get a formula to automatically update to count the number of times a
changing value exists within the same range of cells?

Example:
If my range needs to always be B2:F350, how can I count within that range
how many times the number 1 appears, then 2, then 3, etc.

I have COUNTIF($B$2:$F$350,"=1") but I don't want to have to change the
number every time. I want to copy down so the 1 automatically changes to 2
then 3...

Thanks!


Try this:

=COUNTIF($B$2:$F$350,ROW(1:1))
  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default Countif Question

In the very first row in some column enter:

=COUNTIF($B$2:$F$350,ROW()) and copy down
--
Gary''s Student - gsnu200906


"b4nature" wrote:

How do I get a formula to automatically update to count the number of times a
changing value exists within the same range of cells?

Example:
If my range needs to always be B2:F350, how can I count within that range
how many times the number 1 appears, then 2, then 3, etc.

I have COUNTIF($B$2:$F$350,"=1") but I don't want to have to change the
number every time. I want to copy down so the 1 automatically changes to 2
then 3...

Thanks!

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default Countif Question

In what cells do you want the results to appear?

Let's assume you want the results starting in cell H2.

Enter this formula in H2 and copy down as needed:

=COUNTIF(B$2:F$350,ROWS(H$2:H2))

But, how will you know what that result is for? The first few will be
obvious:

5
7
6
10
12

Why don't you identify the category like this:

1...5
2...7
3...6
4...10
5...12

This is easy to do.

Let's put the category in column H and the counts in column I.

Enter this formula in H2:

=ROWS(H$2:H2)

Enter this formula in I2:

=COUNTIF(B$2:F$350,H2)

Select both H2 and I2 and drag copy down as needed.

--
Biff
Microsoft Excel MVP


"b4nature" wrote in message
...
How do I get a formula to automatically update to count the number of
times a
changing value exists within the same range of cells?

Example:
If my range needs to always be B2:F350, how can I count within that range
how many times the number 1 appears, then 2, then 3, etc.

I have COUNTIF($B$2:$F$350,"=1") but I don't want to have to change the
number every time. I want to copy down so the 1 automatically changes to 2
then 3...

Thanks!



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 question Stuck Excel Worksheet Functions 2 June 23rd 09 03:01 AM
Countif Question cware Excel Discussion (Misc queries) 6 June 10th 09 09:53 PM
COUNTIF question Jock Excel Worksheet Functions 15 March 14th 08 12:32 PM
COUNTIF question Pierre Excel Worksheet Functions 3 February 22nd 07 09:25 PM
COUNTIF question scott Excel Discussion (Misc queries) 1 May 16th 06 06:42 PM


All times are GMT +1. The time now is 06:16 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"