MYSTERY: NESTED INDEX AND MATCH FUNCTIONS
Come to think of it, this is much easier than we're making it out to be.
If there is only 1 *numeric value* in the range this will suffice:
=MAX(Data!B3:B52)
--
Biff
Microsoft Excel MVP
"T. Valko" wrote in message
...
Did you try the formula?
=LOOKUP(1E100,Data!B:B)
That formula will return the *last numeric value* from Data column B.
You say your UDF extracts the numeric portion from a string and places
that *one numeric value* somewhere in Data column B.
If there is only one numeric value in Data column B then it also has to be
the *last numeric value* and the above formula will find it.
If the formula didn't work (will return #N/A if no numeric values are
found) then you don't have any numeric values in Data column B. Could be
your UDF returns a TEXT number.
Try this generic version. It'll work on both text and numbers.
=LOOKUP(2,1/(Data!B3:B52<""),Data!B3:B52)
--
Biff
Microsoft Excel MVP
"JingleRock" wrote in message
...
Col B, Cells B3 through B52 are blank,
except one -- this displays the CURRENT PRICE.
If "current price" is a numeric value try this:
=LOOKUP(1E100,Data!B:B)
--
Biff
Microsoft Excel MVP
Biff,
Thanks for your response.
I think that I didn't explain my situation very well, so I will
elaborate.
'CURRENT PRICE' consists of 6 digits and a decimal embedded in a
string; this price will change daily. This sub-string will be in an
indeterminable row on a daily basis and will be of the form ...
" CURRENT PRICE 6.54321 ". My UDF will
extract the '6.54321' and place the result in Col B (formatted as
"General"). There will only be one such string in the Data Sheet
daily; that is why there will be only one displayed value in the range
B3:B52 (the UDF evaluates to a blank cell if there is no "CURRENT
PRICE" in that row). The trick is getting the day's CURRENT PRICE to
the Values Sheet.
JingleRock
|