Question:
Microsoft Excel conditional formatting question?
Kurt
2010-05-27 15:42:39 UTC
I am trying to incorporate conditional formatting in a cell ONLY when text has been entered into a different cell.

Right now I have a cell, A1, with a desired response.

If I put an undesired response into cell B1, B1 will turn red. If I put the desired response into cell B1, B1 will turn green.

Right now if A1 is empty and B1 is populated, B1 will turn red (because A1 is blank and B1 is populated, so they don't match).

Is there any way that this conditional formatting applied to B1 would ONLY take place if A1 is populated. (Meaning that if A1 is blank the conditional formatting in B1 will be disregarded).

Or is there a way that I could add another conditional format to B1 as if to say 'If A1 is empty, fill B1 with a third color?'
Three answers:
garbo7441
2010-05-27 16:26:27 UTC
You would need to use a formula in the conditional formatting structure. For example, if you wanted B1 to turn Red if it contained the text 'Stop' and A1 was not blank, and Green if the text was 'Go' and A1 was not blank, do this:



Select cell B1 and go to conditional formatting.



Change the drop down under Condition1 to 'Formula is'.



In the text box to the right enter the formula:



=AND(A1<>"",B1="Stop")



Click 'Format',set the Pattern as Red, and click 'OK'.



Click 'Add>>' at the bottom.



In the drop down beneath Condition2 select 'Formula is'.



In the text box to the right enter the formula:



=AND(A1<>"",B1="Go")



Click 'Format',set the Pattern as Green, and click 'OK'.



Click 'OK' to complete the formatting.



Conditional formatting will now be in effect.



If you want to conditionally format a range of cells in column A such as A1:A10, highlight the range A1:A10, go to Conditional formatting and use the same formulas/structure as above. Excel will adjust each cell to the proper references.
florene
2016-06-03 10:33:19 UTC
There shouldn't be a problem. You can change font, colour, size, style, enhancement, bold, italics etc. borders in cell, and pattern so there are several changes you can make. But I'm wondering if you are actually referring to the condition, as in between so and so and so and so. If the choice here is not sufficient, then I can only assume you have not designed your spreadsheet in quite the right way. Excel didn't change that much with XP2002 and 2003 versions, but it is so very different with 2007!
2010-05-27 15:54:42 UTC
click Add>> in conditional formatting dialog box


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Continue reading on narkive:
Loading...