#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3
Default Formula

How do I create a simple counter to show repeating values?
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 772
Default Formula

It all depends what you are trying to count and how you want to show it. are
you wanting something that increments automatically as a duplicate is entered
or like a button that takes a number up and down? Or just a count of all
duplicate data?
--
-John
Please rate when your question is answered to help us and others know what
is helpful.


"User279" wrote:

How do I create a simple counter to show repeating values?

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3
Default Formula

Yes something that increments automatically as duplicates are entered.

"John Bundy" wrote:

It all depends what you are trying to count and how you want to show it. are
you wanting something that increments automatically as a duplicate is entered
or like a button that takes a number up and down? Or just a count of all
duplicate data?
--
-John
Please rate when your question is answered to help us and others know what
is helpful.


"User279" wrote:

How do I create a simple counter to show repeating values?

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3
Default Formula

Thank you, I'll try it

"John Bundy" wrote:

Here is a formula from way back that counts uniques, you can change to bring
back duplicates or just subtract the result from the count of cells.

Function CountUnique(ItemList As Range) As Long

' CountUnique counts the number of cells in a range of cells, but only
' counts cells that have duplicates once. Thus it is like the Excel
' COUNT function except that it only counts unique values.

' Written by: Damon Ostrander
' Date: 5/3/01
' Email:

Dim nItems As Long
Dim i As Long
Dim j As Long

nItems = ItemList.Cells.Count
CountUnique = 0
For i = 1 To nItems
For j = 1 To i - 1
If ItemList.Cells(i) = ItemList.Cells(j) Then GoTo Duplicate
Next j
CountUnique = CountUnique + 1
Duplicate:
Next i

End Function


--
-John
Please rate when your question is answered to help us and others know what
is helpful.


"User279" wrote:

Yes something that increments automatically as duplicates are entered.

"John Bundy" wrote:

It all depends what you are trying to count and how you want to show it. are
you wanting something that increments automatically as a duplicate is entered
or like a button that takes a number up and down? Or just a count of all
duplicate data?
--
-John
Please rate when your question is answered to help us and others know what
is helpful.


"User279" wrote:

How do I create a simple counter to show repeating values?



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



All times are GMT +1. The time now is 01:14 PM.

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"