View Single Post
  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Sandy Mann Sandy Mann is offline
external usenet poster
 
Posts: 2,345
Default can't lookup a value to the left of my variable

Others have given you a formula that works, the reason that your formula
failed is because as it says in Help:

"Important The values in lookup_vector must be placed in ascending order:
....,-2, -1, 0, 1, 2, ..., A-Z, FALSE, TRUE; otherwise, LOOKUP may not give
the correct value."

Because your sample was ascending it does work with the sample data but may
not with real data.

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings


Replace @mailinator.com with @tiscali.co.uk


"Gluefoot" wrote in message
...
I cannot figure out how to return the value of a cell to the left of my
reference. For example I have a table that looks like this....
A B C
1Bob 1 5
2John 2 6
3Tom 3 7
4Tim 4 8

I need to find the number 7 in column C and return the value of the cell
in
column A with the same row number. Make sense? i tried something like
this:
=LOOKUP(7, C1:C4, A1:A4) but that keeps returning the wrong value. also,
column A is not and cannot be sorted alphabetically.