Thread: Vlookup
View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Vlookup

Jeff,

Tinker with the criteria bit, ie this part:
...(Sheet2!A$1:A$100=A1))*(Sheet2!C$1:C$100<=C1)..

Your line/new query :
..only brings back the one that's occured within the previous 30 days?

would suggest that: TODAY()-30
is an additional, lower limit to be applied for the dates in col C,
ie an added criteria: (Sheet2!C$1:C$100=TODAY()-30)

Hence you could try building it on like this for the criteria part:
... (Sheet2!A$1:A$100=A1))*(Sheet2!C$1:C$100=TODAY()-30)
*(Sheet2!C$1:C$100<=C1) ..

--
Max
Singapore
http://savefile.com/projects/236895
Downloads:27,000 Files:200 Subscribers:70
xdemechanik
---
"JeffK" wrote:
Actually after looking a bit closer, the formula brings back the rating that
took place on or before the opening date, but if there's more than one that
fits the criteria, it will bring back the first one it comes to.

How do I change it so it only brings back the one that's occured within the
previous 30 days?