0
votes

I did a lot of research on this topic, but could not find a solution. I created a macro to search for value and put it in the cell. My program returns me error i.e 1004 which means data not found. I debugged the program and found that the value, when it was fetched it was "TSK0000000788", but when I incorporated that variable in the VLOOKUP function it changed it to "TSK788". I also tried to change the format of cell, just to see if it helps, when I changed it to Text, Formula was not working. By default it was set to General only. Is this error common?

1
Can you provide a public link to your example file and code by uploading to drop box or one drive or other similar sites. - skkakkar
Is it possible you applied a custom format to that data and that the zero's were applied by formatting? - nicolaus-hee

1 Answers

0
votes

I have tested VLOOKUP function with various formats in the Table, so Long as your Lookup value is ("TSK788") in the function, it works correctly. Please try your function on a new workbook on a new sheet after pasting data on some Text Editor like Note Tab Light or Note pad and the again copying and pasting data to your new worksheet. Please see if the problem still persists.