View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Dana DeLouis Dana DeLouis is offline
external usenet poster
 
Posts: 947
Default max function with a less than or equal to

basically need a max function something like this:
Max(A1:A5)<B1


Here's an Array equation. (Ctlr+Shft+Enter)

=MAX(IF(A1:A5<B1,A1:A5))

--
HTH. :)
Dana DeLouis
Windows XP, Office 2003


"masterbaker" wrote in message
...
I am looking for a way to utilize the max or maxa functions that returns a
value depending on if it's less than a value. Assume:

B1 value is 8
A1:A5 values a
2
4
6
9
15

I want a function that returns one of the values in A1:A5 that is the
largest number less than B1. This example would return the value 6. I
basically need a max function something like this:

Max(A1:A5)<B1 (Return the maximum number of A1:A5 that's less than B1)

This returns a false statement because the maximum number of A1:A5 is not
less than B1, but I want the value of 6 to be returned because it is the
largest number in the array that's less than B1. PLEASE HELP.

Thanks in advance for anything from anyone!