View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
JMB JMB is offline
external usenet poster
 
Posts: 2,062
Default Help with a statement

where A1 is the number you're trying to find in Sheet2!A1:C13, try:

=MIN(IF(Sheet2!A1:C13=A1,ROW(Sheet2!A1:C13)))

array entered w/Cntrl+Shift+Enter. change ranges as needed (but cannot use
entire columns, such as A:C). it should give you the first row in which that
number appears.

or for the relative row reference
=MIN(IF(Sheet2!A1:C13=A1,ROW(Sheet2!A1:C13)-ROW(Sheet2!A1)+1))

(which makes no difference in this specific example since the data is in the
first row of Sheet2) also array entered.


"Help Needed!!!" wrote:

Help would be greatly appreciated. Example is below.

I need a statement that would do the following:

match a number within a column in sheet1 with several columns in sheet2 and
the results would import the matching number's row from sheet2 to sheet 1.