Forum Discussion
Conditional formatting based on values in either of 2 other cells.
KatWarren , you may apply to your range (assume starts from C1) conditional formatting rule with formula
=(A1=5)+(B1=5)
SergeiBaklanYes, I am applying the range for the entire column. It is actually more complicated even... Here is the table... column D indicates the color I need column C.
A B C C
| 5 | 5 | 25 | red |
| 5 | 4 | 20 | red |
| 5 | 3 | 15 | red |
| 5 | 2 | 10 | orange |
| 5 | 1 | 5 | yellow |
| 4 | 5 | 20 | red |
| 4 | 4 | 16 | red |
| 4 | 3 | 12 | orange |
| 4 | 2 | 8 | yellow |
| 4 | 1 | 4 | green |
| 3 | 5 | 15 | red |
| 3 | 4 | 12 | red |
| 3 | 3 | 9 | orange |
| 3 | 2 | 6 | yellow |
| 3 | 1 | 3 | green |
| 2 | 5 | 10 | red |
| 2 | 4 | 8 | red |
| 2 | 3 | 6 | orange |
| 2 | 2 | 4 | green |
| 2 | 1 | 2 | green |
| 1 | 5 | 5 | red |
| 1 | 4 | 4 | orange |
| 1 | 3 | 3 | yellow |
| 1 | 2 | 2 | green |
| 1 | 1 | 1 | green |
- KatWarrenApr 20, 2019Copper Contributor
Actually, I think I can make this more simple, now that I did that... to just do conditional based on the product...
KatWarren wrote:SergeiBaklanYes, I am applying the range for the entire column. It is actually more complicated even... Here is the table... column D indicates the color I need column C.
A B C C
5 5 25 red 5 4 20 red 5 3 15 red 5 2 10 orange 5 1 5 yellow 4 5 20 red 4 4 16 red 4 3 12 orange 4 2 8 yellow 4 1 4 green 3 5 15 red 3 4 12 red 3 3 9 orange 3 2 6 yellow 3 1 3 green 2 5 10 red 2 4 8 red 2 3 6 orange 2 2 4 green 2 1 2 green 1 5 5 red 1 4 4 orange 1 3 3 yellow 1 2 2 green 1 1 1 green - SergeiBaklanApr 20, 2019Diamond Contributor
KatWarren , to apply the conditional formatting you need to have some formal logic for such conditions, after that convert it to formulas for the rules. I didn't catch what is the logic here.
- KatWarrenApr 20, 2019Copper Contributor
SergeiBaklanYes. The more I looked at it, the more I see the lack of pattern.