Find column header text from assigned ID in lookup table

BradleyS

Active Member
Joined
Oct 28, 2006
Messages
344
Office Version
  1. 2010
Platform
  1. Windows
I need to find the corresponding column header text, using the ID where there is data in the table cells B2:E9
It doesn't matter what is written in the table cells B2:E9, anything other than blank.
Each ID can ONLY be assigned to 1 column
In the example id 0 should = Shoe
I've tried using INDEX/MATCH, but it doesn't work after the 4th row, which I think is because the lookup sizes need to be the same. In which case what can I use instead?

Book1
ABCDEFGH
1idHatCoatShoeShirt
24a
32xid0
47yAnswer#REF!
58r1
60w
731
834wg
914554
Sheet1
Cell Formulas
RangeFormula
H4H4=INDEX(B1:E1,MATCH(H3,A2:A9,0))
 

Excel Facts

Highlight Duplicates
Home, Conditional Formatting, Highlight Cells, Duplicate records, OK to add pink formatting to any duplicates in selected range.
How about
Excel Formula:
=INDEX(B1:E1,MATCH("?*",INDEX(B2:E9&"",MATCH(H3,A2:A9,0),0),0))
 
Upvote 0
Solution
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,221,310
Messages
6,159,176
Members
451,543
Latest member
cesymcox

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