![]() |
vlookup error
I have two different cells containing two data say C1=1,D1=2, I also have a
table containing data say F1:K5 where data in column F is a combination of C1 & D1 with "." inbetween exp 1.2, I use vlookup(C1&"."&D1,F1:K5,3) in cell A1 to display the result of relative cell data in column K, somtimes it works but somtimes it doesn't and says "moving or deleting cells caused an invalid cell reference, or function is returning reference error". Besides, I wrote a macro like ---Range("A1").Select ActiveCell.FormulaR1C1 = _ "=VLOOKUP(C1&"".""&D1,F1:K5,3)" It also shows the same error message, how can I solve this problem please? |
vlookup error
Try this
ActiveCell.Formula = "=VLOOKUP(C1&D1 ,F1:K5,3)" Mike "Seeker" wrote: I have two different cells containing two data say C1=1,D1=2, I also have a table containing data say F1:K5 where data in column F is a combination of C1 & D1 with "." inbetween exp 1.2, I use vlookup(C1&"."&D1,F1:K5,3) in cell A1 to display the result of relative cell data in column K, somtimes it works but somtimes it doesn't and says "moving or deleting cells caused an invalid cell reference, or function is returning reference error". Besides, I wrote a macro like ---Range("A1").Select ActiveCell.FormulaR1C1 = _ "=VLOOKUP(C1&"".""&D1,F1:K5,3)" It also shows the same error message, how can I solve this problem please? |
vlookup error
In addition Mike's suggestion, are you copying the formula down to other
cells? If so, then the table array in the formula should be absolute with the dollar signs like this:- =VLOOKUP(C1&"."&D1,$F$1:$H$5,3) -- Regards, OssieMac "Seeker" wrote: I have two different cells containing two data say C1=1,D1=2, I also have a table containing data say F1:K5 where data in column F is a combination of C1 & D1 with "." inbetween exp 1.2, I use vlookup(C1&"."&D1,F1:K5,3) in cell A1 to display the result of relative cell data in column K, somtimes it works but somtimes it doesn't and says "moving or deleting cells caused an invalid cell reference, or function is returning reference error". Besides, I wrote a macro like ---Range("A1").Select ActiveCell.FormulaR1C1 = _ "=VLOOKUP(C1&"".""&D1,F1:K5,3)" It also shows the same error message, how can I solve this problem please? |
vlookup error
Hi Mike,
It works, tks "Mike H" wrote: Try this ActiveCell.Formula = "=VLOOKUP(C1&D1 ,F1:K5,3)" Mike "Seeker" wrote: I have two different cells containing two data say C1=1,D1=2, I also have a table containing data say F1:K5 where data in column F is a combination of C1 & D1 with "." inbetween exp 1.2, I use vlookup(C1&"."&D1,F1:K5,3) in cell A1 to display the result of relative cell data in column K, somtimes it works but somtimes it doesn't and says "moving or deleting cells caused an invalid cell reference, or function is returning reference error". Besides, I wrote a macro like ---Range("A1").Select ActiveCell.FormulaR1C1 = _ "=VLOOKUP(C1&"".""&D1,F1:K5,3)" It also shows the same error message, how can I solve this problem please? |
All times are GMT +1. The time now is 10:03 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com