Hi All,
My VBA Vlookup is working, but producing the wrong results, because I don't have an exact match of the text between the table where my formula goes, and the lookup table. Please help if you're able. I'd greatly appreciate it. Below is my functioning formula.
Y4 = Range("A1", Range("A1").End(xlDown)).Rows.Count
For n = Y4 - 3 To 2 Step -1
Cells(n, 4).FormulaR1C1 = "=VLOOKUP(RC[-2],'[event master lookup table.xls]Sheet1'!C1:C4,4)"
Next n
it works for lookup values from table A, that have no other values similar in table B, such as "YO GABBA GABBA! LI" which is in table A, "Yo Gabba Gabba - AC Entertainment and Broadway Series South" which is in table B. I am not using exact match because the wording from table to table is not the same.
The problem comes when I have a value in table A that is very similar to values in table B. The V lookup seems to pick the first close match, not the one that is really the matching title. Ex. "THE GIBSON BROTHER" is in Table A, and "The Gathering: A Holiday Concert - PineCone Piedmont Council of Traditional Music" and The Gibson Brothers - PineCone Piedmont Council of Traditional Music" are consecutive row entries in table B. The Vlookup seems picks, ""The Gathering: A Holiday Concert - PineCone Piedmont Council of Traditional Music", even though the "lookup value referred to with R1C1 notation is actually "THE GIBSON BROTHER". I think this is because the Vlookup is only matching the first several characters of the "lookupvalue" R1C1 reference, but I'm not sure, and I'd love for this vlookup to work correctly. I'd thought that, if there's a way to put a wildcard (*) on the R1C1 reference, so that it looks for any of the contents in the cell, not just the first few letters, that'd be great, but I've been searching online so far, with no success.
Thanks for any help you can give!
Musicman715
Bookmarks