Creat table list

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How can I set up table list with doctor's last name first , with first name
initials and with their tittles. So that when you enter in a name of a doctor
their GP practice code comes up automatically within the adjacent cell?
 
Hi,

1 way. Create a simple table like this
A B C
Doc Halliday 123 Doc Halliday
Doc Crippen 456
Doc Doolittle 789

In another cell type the formula

=VLOOKUP(C1,A1:B3,2,FALSE)

This looks for a name in C1 and returns the number next to that name from
the table.

Mike
 
Something like this ....say on Sheet2


A B C D E
Last name First Name Initial Title GP practice Code
Smith John M Dr 12345

IF the last names are unique, you could use VLOOKUP to get other information
from the table:

Assume Surnames in drop down list (see Data Validation) in column A, startin
row 2:

in B2:

=VLOOKUP(A2,Sheet2!A:E,5,0) will return the Practice Code for Surname in A2

If Last Names are NOT unique, you will need to match on two (or more) fields
e.g Last Name, First Name so these need to be provided in the selection.

HTH
 
Back
Top