View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
CarlosAntenna
 
Posts: n/a
Default Use Vlookup to find less than today

To account for weekends, you would need to expand on daddy's formula like
this:

=IF(WEEKDAY(E4,2)=1,VLOOKUP(E4-3,'e1'!H:I,2,1),VLOOKUP(E4-1,'e1'!H:I,2,1))

--
Carlos

"Bruce" wrote in message
...
I have the following array that uses a date to lookup my array (i.e. in

E4).
=VLOOKUP(E4,'e1'!H:I,2,1)

I want to modify this so that it looksup the value less that today. For
example if today is the 25th April 2006 it would return 24th April 2006.

I thought of using dateadd but it would not account for weekends (or

public
holidays in my data. For example the record prior to Monday 24th April

would
be Friday 21st April.

Any ideas?

Bruce