Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

vlookup issue 1

Status
Not open for further replies.

Cpreston

MIS
Mar 4, 2015
972
GB
Hi

I have a sheet with a vlookup which I cannot get to work. In the Vlookup tab column C I want it to bring the information in the data tab column c where column A in both sheets match.

But I am getting #N/A for all of the results. I have googled how to the vlookup so I think I have it right but could be wrong of course.

I have attached an example of the sheet

Thanks in advance for any assistance.
 
 https://files.engineering.com/getfile.aspx?folder=4a86c4af-080f-43db-9018-a9ea0e822a2f&file=customer_list_definitions_testing.xlsx
Col. 1 in Data sheet contains text with apostrophe as first character, so no match.

combo
 
... and since your workbook has a data mismatch, you can compensate by converting your lookup value from a number to a string of 4 digits.

[tt]
C1: =VLOOKUP(TEXT(A1,"0000"),Data!A:C,3,FALSE)
[/tt]
...COPY N PASTE down.

FYI: faq68-6659


Skip,
[sub]
[glasses]Just traded in my OLD subtlety...
for a NUance![tongue][/sub]
"The most incomprehensible thing about the universe is that it is comprehensible" A. Einstein

You Matter...
unless you multiply yourself by the speed of light squared, then...
You Energy!
 
Ouch how stupid of me I didnt notice the Data sheet contains text with apostrophe and also thanks Skip the =VLOOKUP(TEXT(A1,"0000"),Data!A:C,3,FALSE) worked perfect.

Thanks as always
 
For such cases I have procedure that edits cells and assigns the same formulas. If cells are not formatted as text, numbers as text are converted to numbers. It can be applied to values in col. A, 'Data' sheet. The macro converts selected range:

[pre]Sub ReEnterFormula()
Dim c As Range
For Each c In Selection
With c
.Formula = .Formula
End With
Next c
End Sub[/pre]


combo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top