Help With Formula For Date Comparison

F

foofoo

Hello -

Can anyone help me with a formula involving dates? I'm stumped. . .

I need to write the formula in cell A1. The formula needs to compare
today's date (in cell A2) with dates entered in calls A4 and A5. If
today's date in A2 is equal to or between the dates in cells A4 and
A5, AND if cell A8 which contains notes is blank, then the formula
result should display "Extract". If these conditions are not met,
then the formula result should display "Not Extract".

Examples of what I am looking for are shown below:

EXAMPLE 1
A1 A2 A4 A5 A8
Extract 9/6/07 9/4/07 9/24/07

EXAMPLE 2
A1 A2 A4 A5 A8
Not Extract 9/6/07 9/4/07 9/24/07 received via e-mail



Thanks!


Sandi
 
G

Guest

See if this formula does what your asking:

=IF(AND(OR(AND(TODAY()=A2,TODAY()=A3),AND(TODAY()>=A2,TODAY()<=A3)),NOT(ISBLANK(A5))),"Extract","Not Extract")
 
R

Rick Rothstein \(MVP - VB\)

Does this do what you want?

=IF(AND(A2>=A4,A2<=A5,A8=""),"Extract","Not Extract")

Rick
 
S

Sandy Mann

Another way adapting one of Harlan's formuals:

=IF(MEDIAN(A2,A3,A4)=A2,"Exact","Not exact")

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

(e-mail address removed)
Replace @mailinator.com with @tiscali.co.uk
 
R

Rick Rothstein \(MVP - VB\)

You left out the A8="" condition.

Is there a benefit to using the single MEDIAN comparison as opposed to
AND'ing two comparisons?

Rick
 
S

Sandy Mann

Rick Rothstein (MVP - VB) said:
Is there a benefit to using the single MEDIAN comparison as opposed to
AND'ing two comparisons?


Only when you miss out the A8="" <g>

--
REgards,

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

(e-mail address removed)
Replace @mailinator.com with @tiscali.co.uk
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Alpha sorting (with a twist...?) 3
consecutive date numbering by rows of 4 5
Formula For Date Comparisons 2
auto sum 5
date range 11
average formula? 8
COUNTIF between dates and if value = "y" 8
Average Question 2

Top