Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
JaB JaB is offline
external usenet poster
 
Posts: 23
Default Look Up or Maybe IF formula

Hi there

I am trying to create a formula that looks in cell A1 in sheet B for a
matching value in A. When it finds the value in sheet A, I want it to copy
the next 10 cells in the corresponding row into cells B1, C1 etc...

Any advice appreciated.

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default Look Up or Maybe IF formula

One way:

Select the 10 cell range B1:K1

Enter this array formula** :

=OFFSET(Sheet1!A1,MATCH(A1,Sheet1!A1:A10,0)-1,1,,10)

** array formulas need to be entered using the key combination of
CTRL,SHIFT,ENTER (not just ENTER)

--
Biff
Microsoft Excel MVP


"JaB" wrote in message
...
Hi there

I am trying to create a formula that looks in cell A1 in sheet B for a
matching value in A. When it finds the value in sheet A, I want it to
copy
the next 10 cells in the corresponding row into cells B1, C1 etc...

Any advice appreciated.

Thanks



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 10,124
Default Look Up or Maybe IF formula

One way

Sub copymatchingline()
For Each c In Range("b5:b6") 'destination range
With Sheets("sheet2")
ma = .Range("a2:a22").Find(c).Address
.Range(ma).Resize(1, 10).Copy c
End With
Next c
End Sub

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"JaB" wrote in message
...
Hi there

I am trying to create a formula that looks in cell A1 in sheet B for a
matching value in A. When it finds the value in sheet A, I want it to
copy
the next 10 cells in the corresponding row into cells B1, C1 etc...

Any advice appreciated.

Thanks


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 07:05 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"