LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default Count occurances in a range.

I am using Excel 2007 and windows 7
I have a range of cells C5:F32 which is full of numbers.
I am running code which steps me through every cell starting with the first column C5 to C32, moving to the next column and doing the same and ending with the last Number in column F.
When it stops at each cell I need to determine how many times the same number has appeared in that range in rows prior to the row of the cell I am currently in.
That determines if the number of the cell I am currently in is the 1st 2nd, 3rd or 4th time that number has appeared. The same number is never repeated in the same row so it only has to count the number of times it appears in previous rows and then obviously add 1 to determine the 1st 2nd etc. Numbers appearing in the first row will always be the first time they appear but the first time a number appears could also be in any other row.The result of the number of times it has occured is posted in cell U1
Can anyone help with the code I need.
 
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
How do I count occurances of a specific character in a range? Viridel Excel Worksheet Functions 1 January 18th 08 01:55 AM
Count occurances within a date range Marc Excel Discussion (Misc queries) 6 March 6th 07 04:29 PM
count number of occurances of a word in a range John Davies Excel Worksheet Functions 3 February 24th 06 01:46 PM
Count occurances in range of cells Ed Gregory Excel Worksheet Functions 1 September 7th 05 04:12 PM
count date occurances in range of dates... Alex Excel Worksheet Functions 2 July 27th 05 04:15 PM


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