1

For example, given the sheet below:

A colourful sheet

I'd like the background colours of columns B-D to change automatically when I update the values in column A

Is that possible? I'm looking for a solution that will work with any colour, without preprogramming the sheet in some way to be aware of a fixed set of colours.

6
  • 3
    Possible duplicate of Google Spreadsheets conditional formatting based on another cell's content
    – Rubén
    Feb 17, 2016 at 16:06
  • I would say that it's a more specific case of the proposed duplicate question. I specifically want to use the other cell as a source for deciding the colour of another cell.
    – Matt
    Feb 17, 2016 at 16:51
  • I don't see the difference. The referred Q&A include answers to apply conditional formatting by using a script and by using the built-in feature. Regarding the last, see webapps.stackexchange.com/a/53559/88163
    – Rubén
    Feb 17, 2016 at 17:00
  • 1
    If you want to color of the conditional formatting to be pulled from the source cell, you're going to be in scripting land. Feb 17, 2016 at 20:21
  • If you make that an answer (rather than a comment) I'll select it as the best answer.
    – Matt
    Feb 17, 2016 at 20:24

1 Answer 1

2

Going to answer this one as the answer from the post: "Google Spreadsheets conditional formatting based on another cell's content" is outdated.

To answer your question: Highlight the Range that you need conditional formatting, then go to "Format > Conditional Formatting" and for each Color you will add a unique conditional format.

  • Apply to Range: the range you selected previously

  • Format Cells if: "custom formula"

    • Formula in plain English: Anything in the corresponding cell in column A on the same Row that contains the characters "Red", the formula would be:

      =A:A="Red" 
      
    • And then just choose red background from the color picker in the conditional formatting sidebar.

    • Repeat this process for each color.

Example file here: https://docs.google.com/spreadsheets/d/1sJtSrvFpKxmxUgzvrtIQzhYmxqeoR0FWVHpzNV5bIgQ/edit?usp=sharing

4
  • How, in your example scenario, would I go about getting the background of a row to be, say, blue?
    – Matt
    Feb 17, 2016 at 20:28
  • Highlight Row, the right click > Conditional Formatting and would setup something like this: prntscr.com/a52j1w Feb 18, 2016 at 22:40
  • Thanks @David Knapp. Is it possible to extend this method to colour an entire row rather than just one cell?
    – Matt
    Feb 24, 2016 at 16:46
  • yes just highlight the entire row and then apply the conditional formatting rules to that row. Feb 25, 2016 at 19:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.