View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default How can I look up a value from a table and return data for other column

Application.Vlookup

use the excel worksheet function Vlookup (in VBA).

--
Regards,
Tom Ogilvy


"Wellie" wrote in message
...
I have a table with 2 columns of data as shown in sample
below.

Col-A Col-B
Apple A
Pear P
Orange O

In a Cell say D1, I used "Data" - "Validation" to create
a dropdown box (combo box) by sellected Col-A as list
which allow me to select from Col-A. However, what
function I can use at the same to also return to me the
corresponding value in column-B instead of the selecte
item ?

E.g Select Pear, the function returns to me letter P.

Any assistance is greatly appreciated.