Frist match from three arrays

Calgary_Neil

Board Regular
Joined
Apr 5, 2014
Messages
79
Hello again;

I was trying to use the follow formula
=MIN( SUMPRODUCT( N( MOD( COLUMN( Production!$C82:$FI82)+4, 7)=0),
N( Production!$C82:$FI82= 1 ),
COLUMN( Production!$C82:$FI82) ))
to return the column number of the the first cell to have 1. It should return 3, but returns 13 (3 +10).
It is returning the sum of the columns that have 2 (Duh).

The Sumproduct works as follows:
Part A creates a mask for the cells I'm interested in. 1,0,0,0,0,0,0,1 ...
Part B checks all cells for the Value (1) 1,0,0,0,0,0,0,1 ...
Part C returns the the column number 3,4,5,6,7,8,9,10, ...
The Min doesn't do anything (bahh)

Neil Excel 365
 
Last edited:

Excel Facts

Select all contiguous cells
Pressing Ctrl+* (asterisk) will select the "current region" - all contiguous cells in all directions.
What a brain fart this is.
replace min( sumproduct( with small(
the commas within sumproduct with *
add ,2 at the end (zero will always be smallest)
Ahis gives
 
Upvote 0

Forum statistics

Threads
1,224,836
Messages
6,181,251
Members
453,027
Latest member
Lost_in_spreadsheets

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