+ Reply to Thread
Results 1 to 4 of 4

Changing Colour of Cells (Influenced by Drop Down List)

  1. #1
    Registered User
    Join Date
    11-01-2011
    Location
    Nottingham, England
    MS-Off Ver
    Excel 2007
    Posts
    12

    Changing Colour of Cells (Influenced by Drop Down List)

    Hello!

    Please take a look at the simple spreadsheet I have attached to this post. If we take row 2 as an example, you can see there is a drop down option on cells D2 and E2. The only value that can be displayed in these cells is either Yes or No.

    I would like the following rules to apply to Row 2, Cells A to E:-

    If Cell D2 is "Yes" and Cell E2 is "Yes" - Cells A2 to E2 are shaded green.
    If Cell D2 is "Yes" and Cell E2 is "No" - Cells A2 to E2 are shaded orange.
    If Cell D2 is "No" and Cell E2 is "Yes" - Cells A2 to E2 are shaded orange.
    If Cell D2 is "No" and Cell E2 is "No" - Cells A2 to E2 are shaded red.

    I believe conditional formatting only allows you to change the cell colour determined by the value in that cell, so I am not sure how to make other cells change as determined by the value in an adjoining cell.

    Hope someone can help me, many thanks in advance.
    Attached Files Attached Files
    Last edited by Karelia Suite; 12-12-2011 at 09:20 AM.

  2. #2
    Valued Forum Contributor mohd9876's Avatar
    Join Date
    05-04-2011
    Location
    Amman, Jordan
    MS-Off Ver
    Excel 2010
    Posts
    426

    Re: Changing Colour of Cells (Influenced by Drop Down List)

    actually you can use conditional formatting of cells according to the values of other cells using a formula.
    see the attached WB
    Attached Files Attached Files

  3. #3
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: Changing Colour of Cells (Influenced by Drop Down List)

    hi Karelia Suite, please check attachment, try to change values in D or E columns rows 1:11.

    If D or E column value is empty, the row stays uncoloured.

    If nothing happens, run the following code beforehand:

    Please Login or Register  to view this content.
    Attached Files Attached Files

  4. #4
    Forum Expert snb's Avatar
    Join Date
    05-09-2010
    Location
    VBA
    MS-Off Ver
    Redhat
    Posts
    5,649

    Re: Changing Colour of Cells (Influenced by Drop Down List)

    CF1; formula =$D2&$E2="yesyes"
    CF2; formula =$D2&$E2="nono"
    CF3; formula =or($D2&$E2="yesno";$D2$E2="noyes")



+ 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