How do I select the nearest date from a ranges of dates?

G

gerrit

Hello,
suppose you have a range of dates and you would like to select the nearest
future date. For exemple, range of possible monthly repayment dates goes from
1st Jan over 1st Feb to 1st December. Today it is 12th Feb so the first next
possible redemption date should be 1st March. On 24th June, the first
possible redemption date should be 1st July.

My question is, is there anybody who can explain me how to program such a
formula in excel? Many thanks in advance, Gerrit
 
G

Gary''s Student

If you future or past dates are in column A, then in column B enter:

=IF(A1-TODAY()<0,9999,A1-TODAY())
and copy down


Then sort by column B and take the top entry
 
B

Bob Phillips

=MIN(IF(rng>TODAY(),rng))

which is an array formula, it should be committed with Ctrl-Shift-Enter, not
just Enter.

--

HTH

Bob Phillips

(remove nothere from the email address if mailing direct)
 

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

Top