View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Teethless mama Teethless mama is offline
external usenet poster
 
Posts: 3,718
Default Vlookup with either/or

=IF(COUNTIF(data1,A18),VLOOKUP(A18,data1,4,),VLOOK UP(B18,data1,4,))


" wrote:

Hi,
I'm hoping someone can help me out with what should be an easy task,
but I can't quite get it.
I'm trying to do a Vlookup for 2 columns (either/or) using this
formula:

=VLOOKUP(OR(A18,B18),data1,4,FALSE)

where 'data1' is my array on a separate sheet. It works fine for a
single vlookup, but no luck using the 'or' function.

Does anyone know how to do this?
Thanks in advance for any replies.

Terry