+ Reply to Thread
Results 1 to 2 of 2

dynamic excel table header / column selection

  1. #1
    Forum Contributor
    Join Date
    08-14-2006
    Location
    USA
    MS-Off Ver
    2019
    Posts
    686

    dynamic excel table header / column selection

    =INDEX(Table_1[Col_A],MATCH(1,INDEX((Table_1[Col_B]=$BB$3)*(Table_1[Col_C]=$BC$3)*(Table_1[Col_X]=$BD$3)),0),0))


    Successfully using the above to return Col_A when Col_B, Col_C & Col_X match specific criteria.

    Sometimes I want to match Cols B C & X other times B C & Y or B C & Z

    How can I dynamically specify which column heading to use X Y or Z
    like if $CC1 contained "X" : Table_1[Col_ & $CC1 & ]=$BD$3


    Notes:
    Even if I wanted to, I can't do this with nested ifs as there are too many options.
    Prefer not a volatile option.
    I realize what I'm using is an array but it doesn't require Ctrl-Shft-Enter, which I prefer, as it's too easy for a coworkers to forget this requirement.

  2. #2
    Forum Expert dflak's Avatar
    Join Date
    11-24-2015
    Location
    North Carolina
    MS-Off Ver
    365
    Posts
    7,920

    Re: dynamic excel table header / column selection

    How about INDIRECT("Table_1[Col_" & CC1 & "X]")=
    One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.

    A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 2
    Last Post: 01-29-2015, 07:13 PM
  2. Selection of Excel table column based on a header
    By Alpana Savarna in forum Excel General
    Replies: 3
    Last Post: 10-16-2014, 09:43 AM
  3. Replies: 13
    Last Post: 03-28-2014, 09:36 AM
  4. Replies: 9
    Last Post: 02-26-2014, 04:17 PM
  5. [SOLVED] Find specific value in table and return header row and header column value
    By nelwan in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-30-2013, 01:35 AM
  6. [SOLVED] Extract the column header given the row header and highest value in a subset of a table
    By pguarino in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 09-20-2013, 02:05 AM
  7. [SOLVED] Create Dynamic Column Lookup Reference based on Table Header
    By jeversf in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 01-22-2013, 12:49 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1