Using OFFSET in SUMIF

Patience

Active Member
Joined
Mar 30, 2006
Messages
275
Dear all, it must be Friday as I am bamboozled by OFFSET...

I want to use OFFSET in a SUMIF to define the sum range argument...

Essentially this is the OFFSET (simplified) =OFFSET(K108,-50,0,100) (which when I put a SUM around, works.

But, when I put it as the sum_criteria, I get a blank result. =SUMIF(OFFSET(I108,-50,0,100),I108,OFFSET(K108,-50,0,100))

What I want it to do is look at all the cells from 50 above I108 to 50 below I108, and sum the corresponding cells in colum K.

Makes sense?

Thanks,
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
Dunno why you are facing a problem..

Works fine for me.
Excel Workbook
DE
22ABC100
23DEF200
24GHI100
25ABC300
26DEF210
27GHI510
28ABC310
29DEF420
30GHI100
31
32830
Sheet1
Excel 2003
Cell Formulas
RangeFormula
D32=SUMIF(OFFSET(D26,-4,0,9),D26,OFFSET(E26,-4,0,9))
 
Upvote 0
Or use SUMPRODUCT

=SUMPRODUCT(--(OFFSET(I108,-50,0,100)=I108),OFFSET(K108,-50,0,100))
 
Upvote 0
Great - Thanks again. Thanks for properly testing, too. I didn't mean you to go to that trouble. :)
 
Upvote 0
It's no trouble with FastExcel, just a copy paste and click a button a few times :)
 
Upvote 0

Forum statistics

Threads
1,214,971
Messages
6,122,521
Members
449,088
Latest member
RandomExceller01

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