+ Reply to Thread
Results 1 to 2 of 2

Displaying column header text in a cell on each row, based on the value for that column

  1. #1
    Registered User
    Join Date
    01-30-2014
    Location
    Alabama
    MS-Off Ver
    Excel 2010
    Posts
    1

    Displaying column header text in a cell on each row, based on the value for that column

    Hi,

    I have a rather complicated set of data which I am trying to organize and analyze faster. For simplicity sake I will use example values to describe what I am trying to accomplish. I also attached a picture which has the example table to which I am referring.

    excel question example table.jpg

    I would like to display the name of any Locations (cells D3 through H3) for each Test (cells C4 through C8) that has a value greater than or equal to 3.

    For example, I would like cell C4 (representing "Test1") to display the text "Location 4" and "Location 5" since these locations had a value greater than 3 for "Test 1".

    Likewise I would like cell C5 (representing "Test 2") to display the text "Location 3" since it was the only location for "Test 2" with a value of 3 or greater.

    Thanks for the help and let me know if I need to clarity or define anything else.

    Walter

  2. #2
    Forum Contributor vamosj's Avatar
    Join Date
    04-23-2004
    Location
    Oregon
    MS-Off Ver
    2010
    Posts
    294

    Re: Displaying column header text in a cell on each row, based on the value for that colum

    For this list alone, use the following.

    =CONCATENATE(IF(D4>=3,RIGHT(OFFSET(D4,-(ROW()-ROW($D$3)),0),1)&" ",""),IF(E4>=3,RIGHT(OFFSET(E4,-(ROW()-ROW($D$3)),0),1)&" ",""),IF(F4>=3,RIGHT(OFFSET(F4,-(ROW()-ROW($D$3)),0),1)&" ",""),IF(G4>=3,RIGHT(OFFSET(G4,-(ROW()-ROW($D$3)),0),1)&" ",""),IF(H4>=3,RIGHT(OFFSET(H4,-(ROW()-ROW($D$3)),0),1)&" ",""))


    If there are more locations then you will have to add more IF statements to continue on. This is the only way I know of to do what you are looking for. Hopefully someone knows a better way but I wasn't able to find any possible array formulas that could easily be adjusted in case the location data is dynamic.
    Janos S. Vamos
    Data Systems Technician/Fire Controlman PO1(SW/AW)
    US Navy Retired


    Remember, Record Macro can be your friend for figuring out solutions.

    Good or Bad, let me know how I did by clicking on the "Add Reputation" * just to the lower left of here. it only takes a few seconds to let someone know.

+ 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. Delete column range based on header text
    By sunsoar77 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 08-22-2012, 07:45 PM
  2. [SOLVED] Trying to return a column header in a cell based on a value
    By brianfromla in forum Excel General
    Replies: 2
    Last Post: 06-26-2012, 10:37 AM
  3. Fill Row Header based on cell in column
    By diggerd in forum Excel General
    Replies: 2
    Last Post: 01-06-2010, 09:59 PM
  4. Lookup Column Header based on cell value
    By kingcal in forum Excel General
    Replies: 4
    Last Post: 08-13-2009, 03:56 AM
  5. Displaying column header text in other cells
    By mailgal in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-02-2008, 10:03 AM

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