Choose from a row with limts

jade_00

New Member
Joined
Jul 10, 2008
Messages
4
Hello all,

When I first attempted the following it seemed remarkably simple, yet I am still unable to find a solution.......

I want to have a column that selects the leftmost value in its corresponding row without repeating a previous result.

Ie. Column A is the answer column, and Columns B:E have a list of values in rows.

So, A1 will pick B1, and A2 will pick the leftmost value in Row 2 that has not been selected in A1. A3 will pick the leftmost value in Row 3 that has not been selected by A1 or A2 etc etc.

Make sense? Seems simple, but I haven't been able to figure it out.

I need a formula, not a macro, beacuse I need to enter this at unpredictable times.

Any help would be appreciated.
 

Some videos you may like

Excel Facts

How can you turn a range sideways?
Copy the range. Select a blank cell. Right-click, Paste Special, then choose Transpose.

Andrew Poulsom

MrExcel MVP
Joined
Jul 21, 2002
Messages
73,092
In A2 type:

=INDEX(B2:E2,,MATCH(TRUE,COUNTIF(A$1:A1,B2:E2)=0,FALSE))

and press Ctrl+Shift+Enter, not just Enter. If correctly entered Excel will surround this array formula with curly braces {}.

Copy the formula down. It will return #N/A if all of the numbers in B:E for the current row have already been used.
 

jade_00

New Member
Joined
Jul 10, 2008
Messages
4
Absolutely fantastic - this is EXACTLY what I needed.

Brilliant, thank you so much.
 

Watch MrExcel Video

Forum statistics

Threads
1,122,670
Messages
5,597,482
Members
414,144
Latest member
UDFNewbie

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
Top