Lookup data using an Offset to pull correct cells

excel?

Board Regular
Joined
Sep 14, 2004
Messages
143
Office Version
  1. 365
Platform
  1. Windows
I have data spread out over 17 columns and down 300 rows. I would like to retrieve the amounts from 2 cells relative to a cell that contains a specific number.

I'm hoping you can help with a formula that will lookup the specific number 84001 and retrieve the amount that is located 3 rows below it and a 2nd formula that looks up the same number and retrieves the amount located 3 rows below and 1 column to the right.

The number 84001 is located in a cell in the range C2:S330.

Does anyone have any suggestions on how to accomplish this?

Appreciate any help. Thanks.
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
Hi,

I have 84001 in cell U2 on my sheet, then you could search for any number within range C2:S330 then offset;

3rd row below
Code:
=OFFSET(INDIRECT(ADDRESS(SUMPRODUCT(($C$2:$S$330=$U$2)*(ROW($C$2:$C$330)-ROW($C$1)+1)),SUMPRODUCT(($C$2:$S$330=$U$2)*(COLUMN($C$2:$S$2)-COLUMN($C$2)+3)),4,1),TRUE),3,,)


3rd row below & 1 column to right
Code:
=OFFSET(INDIRECT(ADDRESS(SUMPRODUCT(($C$2:$S$330=$U$2)*(ROW($C$2:$C$330)-ROW($C$1)+1)),SUMPRODUCT(($C$2:$S$330=$U$2)*(COLUMN($C$2:$S$2)-COLUMN($C$2)+3)),4,1),TRUE),3,1,)


You can adjust the offset row or column by testing these numbers in the formula;

,TRUE),3,1,) for row & ,TRUE),3,1,) for column.

 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,181
Members
453,022
Latest member
Mohamed Magdi Tawfiq Emam

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top