I've Two sheets, Sheet1, Sheet2
Sheet1:
A | B
-----
123 |
456 |
789 |
Sheet 2:
A | B
-----
123 | DATA1
789 | DATA2
456 | DATA3
I want The Sheet1 to have the following output:
A | B
-----
123 | DATA1
456 | DATA3
789 | DATA2
I have a very basic VB knowledge, how can I accomplish this?
Sheet1, cell B1:
=VLOOKUP(A1,Sheet2!$A$1:$B$3,2,0)
and drag down should give the desired resultEdit (VBA solution):
Sheet1.Range("B1:B3").Formula = "=VLOOKUP(A1,Sheet2!$A$1:$B$3,2,0)"