Using CELL to form the range in PRODUCT

Alpha1980

Board Regular
Joined
Feb 28, 2008
Messages
125
I need to use the following two formulas

=CELL("Address",INDEX(A1:A10,MATCH(B1,A1:A10,1)))
=CELL("Address",INDEX(A1:A10,MATCH(B2,A1:A10,1)))

to form the range in the following formula:

=PRODUCT(OFFSET(B1,0,1):OFFSET(B2,0,1))

e.g.

=PRODUCT(OFFSET(CELL("Address",INDEX(A1:A10,MATCH(B1,A1:A10,1))),0,1):OFFSET(CELL("Address",INDEX(A1:A10,MATCH(B2,A1:A10,1))),0,1))

However, Excel is telling me that this formula is returning an error.

Can anybody advise how to get around this? 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.
INDEX actually returns a range reference, so there is no need to use CELL.

Try:

=PRODUCT(OFFSET(INDEX(A1:A10,MATCH(B1,A1:A10,1)),0,1):OFFSET(INDEX(A1:A10,MATCH(B2,A1:A10,1)),0,1))
 
Upvote 0
I'm not really clear what you are trying to do, aren't your reference values in B1 and B2 but the formula also seems to be returning the PRODCT range from that column, is that right?

If MrKowz is right then you can also eliminate OFFSET, try

=PRODUCT(INDEX(B1:B10,MATCH(B1,A1:A10,1)):INDEX(B1:B10,MATCH(B2,A1:A10,1)))
 
Upvote 0
Thanks guys.

I started with MrKowz solution and then figured I could indeed remove OFFSET as you suggest, Barry.
 
Upvote 0

Forum statistics

Threads
1,224,599
Messages
6,179,831
Members
452,946
Latest member
JoseDavid

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