Get column header based on value in a table

djgenesis13

New Member
Joined
Apr 24, 2014
Messages
22
I want to search (with a formula) for a value and get the header of the column it exists (preferably without a "helper" column)

I have this table...
ABCDEFGHI
1 JanuaryFebruaryMarchAprilMayJuneJuly
21XXXXAXX
32XXBXXXX
43XXXXXXX
54XXXXXXC
65XXXXXXX
76XXXDXXX
87XXXXXEX
I want to get these results
10AMay
11BMarch
12CJuly
13DApril
14EJune

<colgroup><col span="9"></colgroup><tbody>
</tbody>

Could anyone help?
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
With January in C2
put the values A to E in B10:B14 as your layout suggests

in C10
=INDEX(C$2:I$2,MAX(IF(C$3:I$9=B11,COLUMN(C$1:I$1)-COLUMN(C$1)+1)))
Array formula, use Ctrl-Shift-Enter
and copy down the column
 
Upvote 0

Forum statistics

Threads
1,214,920
Messages
6,122,264
Members
449,075
Latest member
staticfluids

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