ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Array Formula Error (https://www.excelbanter.com/excel-worksheet-functions/217966-array-formula-error.html)

CecesWorking

Array Formula Error
 
I have a data set similar to below

Date Field 1 Field 2 Field 3
1/1/09 x x o
1/5/09 o x x
1/14/09 o o x

I also have an array formula in a separate cell that looks for the row with
the closest match to today's date and is supposed to return the row number
that is the closest match. The formula is:
=MATCH(MIN(ABS($A:$A-TODAY())),ABS($A:$A-TODAY()),0)

But now I receive a new error: #NUM!

All of the dates only live in Column A. I am not sure what I'm doing wrong.

Any help would greatly be appreciated.

Thanks for your time and effort.

JBeaucaire[_97_]

Array Formula Error
 

Try removing the reference to the entire column, just use a range big
enough for your needs:

=MATCH(MIN(ABS($A1:$A20000-TODAY())),ABS($A1:$A20000-TODAY()),0)


--
JBeaucaire
------------------------------------------------------------------------
JBeaucaire's Profile: http://www.thecodecage.com/forumz/member.php?userid=73
View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=54908



All times are GMT +1. The time now is 02:46 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com