ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   matching two worksheets and return to different value (https://www.excelbanter.com/excel-worksheet-functions/115726-matching-two-worksheets-return-different-value.html)

dan

matching two worksheets and return to different value
 
Hello,

Can anyone help me please. I have two worksheet and each contain vendor
code. I just want to match the vendor code and then return to their phone
number.

sheet 1

abc
def
ghi
jkl
mno
pqr
stu
vwx
yza

Sheet 2
vwx 262-5555
jkl 262-5556
pqr 262-5557
mno 262-5558
stu 262-5559
dej 262-5560
ghi 262-5551


Thanks


Teethless mama

matching two worksheets and return to different value
 
=VLOOKUP(A2,Sheet2!$A$2:$B$8,2,0)

adjust your range to suite


"Dan" wrote:

Hello,

Can anyone help me please. I have two worksheet and each contain vendor
code. I just want to match the vendor code and then return to their phone
number.

sheet 1

abc
def
ghi
jkl
mno
pqr
stu
vwx
yza

Sheet 2
vwx 262-5555
jkl 262-5556
pqr 262-5557
mno 262-5558
stu 262-5559
dej 262-5560
ghi 262-5551


Thanks


smw226 via OfficeKB.com

matching two worksheets and return to different value
 
Hi Dan,

You need a Vlookup for this.
It gets a little more complicated amending a formula posted here when they
are on different sheets as it is easy to move a ' meaning your code won't
work.

If you type =vlookup( into your forula bar then click oin the fx to the
left you will get the prompt and should be able to work it out.

Lookup value is the cell on sheet 1 which containts the value you want to
look for on sheet 2

Table array is the whole table on sheet 2 which should have the list of
vendor codes in the far left column and include the value you want to return
(A1:C2)

Col_index_number will be the number of columns accross from the far left
which contains your phone numbers (if the venor code is in column A and the
phone number is in column C, you will want 3)

Range lookup should normally be set to FALSE

HTH

Simon


Dan wrote:
Hello,

Can anyone help me please. I have two worksheet and each contain vendor
code. I just want to match the vendor code and then return to their phone
number.

sheet 1

abc
def
ghi
jkl
mno
pqr
stu
vwx
yza

Sheet 2
vwx 262-5555
jkl 262-5556
pqr 262-5557
mno 262-5558
stu 262-5559
dej 262-5560
ghi 262-5551

Thanks


--
--------------------
Simon - UK

Email at simon22mports [ a t ] hot mail [ d ot ]com

Message posted via http://www.officekb.com



All times are GMT +1. The time now is 03:49 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com