Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 149
Default Looping through 2 workbooks

I have 2 workbooks. One contains a list of data ranges and the other one a
list of date. I would like to check for each date in my 2nd workbook if the
date is in the ranges listed in my f1st workbook.
Example of workbook 1:
1 1/1/2007 2/1/2007
2 3/1/2007 5/1/2007
3 9/1/2007 10/1/2007

Example of workbook 2:
1 1/15/2007
2 1/17/2007
3 9/19/2007

Result should look like this:
1 1/15/2007 1
2 1/17/2007 1
3 9/19/2007 3

Any ideas how I could achieve this?

Thanks



  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 6
Default Looping through 2 workbooks

Try this one:
=sumproduct(('[workbook2]sheet1'!$A$1='[workbook1]sheet1'!$A$1:$A$3)*('[workbook2]sheet1'!$A$1='[workbook1]sheet1'!$B$1:$B$3))
with appropriate workbooks and worksheets names and ranges...

--
A+

V.


"Pierre" wrote:

I have 2 workbooks. One contains a list of data ranges and the other one a
list of date. I would like to check for each date in my 2nd workbook if the
date is in the ranges listed in my f1st workbook.
Example of workbook 1:
1 1/1/2007 2/1/2007
2 3/1/2007 5/1/2007
3 9/1/2007 10/1/2007

Example of workbook 2:
1 1/15/2007
2 1/17/2007
3 9/19/2007

Result should look like this:
1 1/15/2007 1
2 1/17/2007 1
3 9/19/2007 3

Any ideas how I could achieve this?

Thanks



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 6
Default Looping through 2 workbooks

sorry... this would be better:
=sumproduct(('[workbook2]sheet1'!$A1='[workbook1]sheet1'!$A$1:$A$3)*('[workbook2]sheet1'!$A1<='[workbook1]sheet1'!$B$1:$B$3))
--
A+

V.


"Vincnet." wrote:

Try this one:
=sumproduct(('[workbook2]sheet1'!$A$1='[workbook1]sheet1'!$A$1:$A$3)*('[workbook2]sheet1'!$A$1='[workbook1]sheet1'!$B$1:$B$3))
with appropriate workbooks and worksheets names and ranges...

--
A+

V.


"Pierre" wrote:

I have 2 workbooks. One contains a list of data ranges and the other one a
list of date. I would like to check for each date in my 2nd workbook if the
date is in the ranges listed in my f1st workbook.
Example of workbook 1:
1 1/1/2007 2/1/2007
2 3/1/2007 5/1/2007
3 9/1/2007 10/1/2007

Example of workbook 2:
1 1/15/2007
2 1/17/2007
3 9/19/2007

Result should look like this:
1 1/15/2007 1
2 1/17/2007 1
3 9/19/2007 3

Any ideas how I could achieve this?

Thanks



  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 149
Default Looping through 2 workbooks

Thanks!
Pierre

"Vincnet." wrote:

sorry... this would be better:
=sumproduct(('[workbook2]sheet1'!$A1='[workbook1]sheet1'!$A$1:$A$3)*('[workbook2]sheet1'!$A1<='[workbook1]sheet1'!$B$1:$B$3))
--
A+

V.


"Vincnet." wrote:

Try this one:
=sumproduct(('[workbook2]sheet1'!$A$1='[workbook1]sheet1'!$A$1:$A$3)*('[workbook2]sheet1'!$A$1='[workbook1]sheet1'!$B$1:$B$3))
with appropriate workbooks and worksheets names and ranges...

--
A+

V.


"Pierre" wrote:

I have 2 workbooks. One contains a list of data ranges and the other one a
list of date. I would like to check for each date in my 2nd workbook if the
date is in the ranges listed in my f1st workbook.
Example of workbook 1:
1 1/1/2007 2/1/2007
2 3/1/2007 5/1/2007
3 9/1/2007 10/1/2007

Example of workbook 2:
1 1/15/2007
2 1/17/2007
3 9/19/2007

Result should look like this:
1 1/15/2007 1
2 1/17/2007 1
3 9/19/2007 3

Any ideas how I could achieve this?

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
Not Looping Roger Excel Discussion (Misc queries) 0 February 26th 08 05:18 PM
looping through series raymondvillain Charts and Charting in Excel 6 July 16th 07 04:33 AM
Looping macro RK Excel Worksheet Functions 2 December 12th 06 11:29 PM
Looping David T Excel Discussion (Misc queries) 2 August 30th 06 10:51 PM
Looping Question lee New Users to Excel 3 August 4th 06 04:23 PM


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