Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Junior Member
 
Posts: 11
Default Unique values from date range

Dear Sir,

I have following two columns as

-Date------Code
02-06-07----10
02-06-07----20
03-06-07----30
03-06-07----30
03-06-07----40
03-06-07----50
04-06-07----50
04-06-07----60
05-06-07----70
06-06-07----80
06-06-07----90

I am using dateformat="dd-mm-yy"

I wnat to fill Combobox1 with unique codes
between Date 03-06-07 to 04-06-07

The unique values are between date range a 30,40,50,60

Please help
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 4,339
Default Unique values from date range

Assuming your data is in columns A & B, starting row 2:

In C2: =IF(AND($A2=$N$1,$A2<=$N$2),IF(COUNTIF($B$2:$B2,$ B2)=1,$B2,""),"")

and copy down

N1 & N2 contain your dates

in D2:
=IF(ROW()-ROW($D$2:$D$12)+1ROWS($C$2:$C$12)-COUNTBLANK($C$2:$C$12),"",INDIRECT(ADDRESS(SMALL(( IF($C$2:$C$12<"",ROW($C$2:$C$12),ROW()+ROWS($C$2: $C$12))),ROW()-ROW($D$2:$D$12)+1),COLUMN($C$2:$C$12),4)))


Enter with Ctrl+Shift+Enter (aaray formula) which wll put {} round the
formula.


Column D now contains your list

HTH


"tqm1" wrote:


Dear Sir,

I have following two columns as

-Date------Code
02-06-07----10
02-06-07----20
03-06-07----30
03-06-07----30
03-06-07----40
03-06-07----50
04-06-07----50
04-06-07----60
05-06-07----70
06-06-07----80
06-06-07----90

I am using dateformat="dd-mm-yy"

I wnat to fill Combobox1 with unique codes
between Date 03-06-07 to 04-06-07

The unique values are between date range a 30,40,50,60

Please help




--
tqm1

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
How do I count unique values within a date range? Sam Excel Discussion (Misc queries) 5 June 22nd 07 06:15 AM
Find number of unique entries within a date range Gayla Excel Worksheet Functions 1 April 25th 07 11:42 PM
How do I get the unique values from a range? DaveO Excel Worksheet Functions 13 January 13th 06 12:55 AM
Count unique values among duplicates in a subtotal range jcpotwor Excel Discussion (Misc queries) 2 January 12th 06 01:29 PM
Counting unique records based on date range aspAddict Excel Worksheet Functions 3 October 26th 05 08:12 PM


All times are GMT +1. The time now is 04:05 PM.

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"