View Single Post
  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Glenn Glenn is offline
external usenet poster
 
Posts: 1,240
Default VLOOKUP function with embedded LEFT

In this case, it converts the text returned by the LEFT() function into a number
(instead of text that looks like a number). That way it matches the data type
of your table and allows the VLOOKUP() to work properly.

SamB wrote:
Glenn, this worked as well. I have never seen -- used before. What command
is that giving?

"Glenn" wrote:

cm wrote:
I have duplicated your error; the values in your lookup table in sheet2,
a1.... are numbers; replace your formual as follows:

=VLOOKUP(VALUE(LEFT(F2,3)),Sheet2!A1:B335,2,FALSE)

or this:

=VLOOKUP(--LEFT(F2,3),Sheet2!A1:B335,2,FALSE)