Thread: Vlookup error?
View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
tg tg is offline
external usenet poster
 
Posts: 58
Default Vlookup error?

Thank you very much, this works really well!
you guys are great!

"Sheeloo" wrote:

I am assuming that 12 is a number and not text...

LEFT(reference!G3:G7,2) returns a string not a number. This may be the
source of your problem.

Put =ISNUMBER(INDEX(LEFT(reference!G3:G7,2),reference! G9)) in a cell and check

To convert to number you can multiply by 1 and then pass to VLOOKUP.
"TG" wrote:

ok so my problem is when using
=VLOOKUP(INDEX(LEFT(reference!G3:G7,2),reference!G 9),Brackets!A2:F5,6)it
returns a #NA. Where INDEX(LEFT(reference!G3:G7,2),reference!G9) returns a 12!

If i were to put a number 12 instead of
"INDEX(LEFT(reference!G3:G7,2),reference!G9)" then the vlookup function works
as intended.

in other words if i were to just type in
=INDEX(LEFT(reference!G3:G7,2),reference!G9) in a cell it will return a value
of 12, so why does it not work on vlookup.

another thing i have tried is to put
=INDEX(LEFT(reference!G3:G7,2),reference!G9) in lets say Cell A5, it will
return a value of 12 and then i would link this cell to the vlookup fomula
like below:
=VLOOKUP(reference!A5,Brackets!A2:F5,6) and even though "reference!A5"
returns a value of 12, the vlookup function does not work it gives a #N/A.
may this be because Vlookup cannot nest to many references??

Thanks in advance
TG