Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Minimum Date Greater than Today()

1,252 views
Skip to first unread message

VickiMc

unread,
Nov 24, 2008, 11:11:04 PM11/24/08
to
I wanted to write a formula that will find the first date (min) in a range
that is greater/higher than >=today()?
The Match function only likes to return a result less than <today().
My range is non-consecutive cells (Every Fifth column of 240 Columns) in a
row, with multiple cells that would return Greater than today().
And I want the formula to stop evaluating at the first TRUE result.

T. Valko

unread,
Nov 24, 2008, 11:19:25 PM11/24/08
to
>My range is non-consecutive cells
>(Every Fifth column of 240 Columns)

How about telling us what the range is?

--
Biff
Microsoft Excel MVP


"VickiMc" <Vic...@discussions.microsoft.com> wrote in message
news:5F118D1E-65B2-4171...@microsoft.com...

Shane Devenshire

unread,
Nov 24, 2008, 11:46:01 PM11/24/08
to
Hi,

If you mean by first the closest date to today then

=MIN(IF(A1:A10>=TODAY(),A1:A10,""))

Entered as an array - press Shift+Ctrl+Enter

If this helps, please click the Yes button

Cheers,
Shane Devenshire

Shane Devenshire

unread,
Nov 24, 2008, 11:52:01 PM11/24/08
to
Hi,

If you mean first date starting from the top of a range, then

=INDEX(A1:A10,MATCH(1,(A1:A10>=TODAY())*ISNUMBER(A1:A10),0))

Intered as an array. The ISNUMBER excludes the possibility of text entries
in the range.

If this helps, please click the Yes button

Cheers,
Shane Devenshire

JulesMacD

unread,
Sep 10, 2009, 4:46:16 PM9/10/09
to
Hi Shane:

How would you modify this formula if you wanted it to evaluate a range of
cells (F6:F10) but if all the dates were prior to today, it would return the
text in cell F11 (which is 'fully vested')?

T. Valko

unread,
Sep 10, 2009, 5:15:30 PM9/10/09
to
Try this array formula**.

Assuming no text in the range.

=IF(COUNTIF(F6:F10,"<"&TODAY())=ROWS(F6:F10),"Fully
Vested",MIN(IF(F6:F10>=TODAY(),F6:F10)))

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER). Hold down both the CTRL key and the SHIFT
key then hit ENTER.

--
Biff
Microsoft Excel MVP


"JulesMacD" <Jule...@discussions.microsoft.com> wrote in message
news:9E994997-C754-4827...@microsoft.com...

JoeU2004

unread,
Sep 10, 2009, 7:07:46 PM9/10/09
to
"T. Valko" <biffi...@comcast.net> wrote:
> =IF(COUNTIF(F6:F10,"<"&TODAY())=ROWS(F6:F10),
> "Fully Vested",MIN(IF(F6:F10>=TODAY(),F6:F10)))

Or simply:

=IF(COUNTIF(F6:F10,">="&TODAY()),
MIN(IF(F6:F10>=TODAY(),F6:F10)),
"Fully Vested")

Again, that is an array formula. Commit with ctrl+shift+Enter instead of
simply Enter. If you mistakenly commit with Enter, select the cell, press
F2, then press ctrl+shift+Enter.

PS: Instead of using TODAY() in the formula, I suggest that you put
=TODAY() in some cell, then reference the cell. If that cell is A1, the
formula becomes:

=IF(COUNTIF(F6:F10,">="&$A$1),
MIN(IF(F6:F10>=$A$1,F6:F10)),
"Fully Vested")

The reason is: I suspect you will discover that you do not want the
function TODAY() at all, but the value of TODAY() at some time ( i.e.
ctrl+; ). So, for example, when you email the file to someone, the results
will not change when they open the file. It will be easier to change your
design if "today's date" is in one cell instead of repeated throughout the
worksheet.


"T. Valko" <biffi...@comcast.net> wrote in message
news:OV1EVvlM...@TK2MSFTNGP05.phx.gbl...

0 new messages