referencing different workbooks

  • Thread starter Thread starter jimmy
  • Start date Start date
J

jimmy

i have two workbooks. workbook 1 contains 12 columns of
information. the first column is a user key (xyz123 for
example) and the following 11 columns are information
based on that user key. The other workbook has 2 columns,
one containing the user key (xyz123) and the next column
has the actual user name (Doe, JOHN). I want to be able
to somehow populate the user name onto workbook 1 in the
13th column. Thanks for the help!!!
 
You can use a worksheet function:

=vlookup(a1,'[my book2.xls]Sheet1'!$A:$B,2,false)
in that 13th column.

If the key isn't found, you'll get an #n/a back. If you want to hide that, you
can wrap the formula with some error checking:

=if(iserror(vlookup(...)),"Missing",vlookup(...))
 
Back
Top