+ Reply to Thread
Results 1 to 9 of 9

conidtional formatting across columns

  1. #1
    Registered User
    Join Date
    05-09-2011
    Location
    nyc
    MS-Off Ver
    Excel 2003
    Posts
    8

    conidtional formatting across columns

    I have several times to get this work but no dice. So, here it goes:

    I have three columns of data. A column of keys that refer to an object, a columns of objects, and an amount. (The examples is below). I also have a combo box that list all of the keys in column A. Currently, I have the combo box set to populate a single cell with any key that is selected. So, If I scroll down and select e33e, the same key appears in cell F5.

    I am trying to create a conditional formatting that highlights all the cells with the same key. For instance, say I select e33e from the combo box, then A1,B1C1 and A5,B5,C5 all become a specific color, say blue. Or if I select j66j A4,B4,C4 and A6,B6,C6 all turn red.


    I would select A1, go to conditional formatting, new rule, use forumla, and type in:

    =IF(AND($A$1="e33e", $F$5="e33e"), TRUE, FALSE)


    The f5 remember because that is where the combo box populated the word that is selected. So this works and both A3 and F5 turn green whenever I select it on the combo box.

    However, there are two things I cant do properly. I want to set it so that it picks up ALL the keys in column a that have "e33e" (A1 and A5 in the example below) and I want to to highlight the corresponding rows that include the object and amount (so A1,B1,C1 and A5,B5,and C5).

    I have tried several times to in the rules manager to apply the formatting, but it always ends up highlighting the entire column, and not just the specific keys

    Any ideas??

    Thanks so much


    A B C
    e33e candy 100
    f33f corn 7876
    h44h hammer 2365
    j66j box 9854
    e33e candy 99998
    j66j box 13221

  2. #2
    Registered User
    Join Date
    05-09-2011
    Location
    nyc
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: conidtional formatting across columns

    Sorry, this should make the bottom clearer.


    PHP Code: 
    A                 B                  C
    e33e            candy           100
    f33f             corn             7876
    h44h            hammer         2365
    j66j             box               9854
    e33e           candy            99998
    j66j             box               13221 

  3. #3
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: conidtional formatting across columns

    Hi

    Maybe, try without absolute reference...


    =AND($A1="e33e", $F$5="e33e"), TRUE, FALSE)
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

  4. #4
    Registered User
    Join Date
    05-09-2011
    Location
    nyc
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: conidtional formatting across columns

    I tried that before and it did not work, but i just deleted all the rules I because I had like 10 practice ones running, and tried again, and it looks like it works!

    Of course, i am cautiously optimistic, but I'll get back if something goes wrong.

    Thanks a bunch!

    Go greece!

  5. #5
    Registered User
    Join Date
    05-09-2011
    Location
    nyc
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: conidtional formatting across columns

    I tried that before and it did not work, but i just deleted all the rules I because I had like 10 practice ones running, and tried again, and it looks like it works!

    Of course, i am cautiously optimistic, but I'll get back if something goes wrong.

    Thanks a bunch!

    Go greece!

  6. #6
    Registered User
    Join Date
    05-09-2011
    Location
    nyc
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: conidtional formatting across columns

    Does anyone know how to get conditional formatting to pick up multiple characters. For instance, this is the function I am using to highlight the key I need when its in a specific cell.

    =IF(AND($A$1="col3", $F$5="col3"), TRUE, FALSE)


    However, I want to search all of column A for any cell that contains just the three letters "col". So if i select "col" from the combo box, all the keys that begin with col (say, col3,col4,col5....) all get highlighted as well.


    Thanks again guys

  7. #7
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: conidtional formatting across columns

    Hi

    Do you mean something like this?
    Attached Files Attached Files

  8. #8
    Registered User
    Join Date
    05-09-2011
    Location
    nyc
    MS-Off Ver
    Excel 2003
    Posts
    8

    Re: conidtional formatting across columns

    Sort of. Check this out:


    [ATTACH] conditional format example [/ATTACH]


    If you select "col5" or "col7" in the combo box, then the keys "col5" or "col7" in the rows to the left highlight red. However, I also want to select the term "col" in the combo box and have all the keys with the phrase "col", irrespective of the number after it, also to highlight red. So, if I select col, then col5, col7, and any other one that begins with col, will also highlight red. that is where I am stuck.

    Thanks again for the help!
    Attached Files Attached Files

  9. #9
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: conidtional formatting across columns

    Using same logic..
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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