Forum Discussion
conditional formatting if other cell contain value
Hello!
In the column B:B I can have 2 different worlds. I'd like to format the correspondent cell in the column A:A based on the value of B:B.
For example:
HELLO | approved |
HI | approved |
COMPUTER | denied |
TABLET | approved |
EXECEL | approved |
THIS IS AN EXAMPLE | denied |
I'd like to have A1,A1,A4,A5 coloured green and A3,A5 coloured red.
How can I do? How con I refer the rule in an other column?
Thanks!!!
IMHO, it's easier to apply to column A green rule
=$B1="approved"
and red rule
=$B1="denied"
Please see second sheet in attached
- Arul TresoldiIron Contributor
You can create a C:C column with an IF(B1="APPROVED";A1;"") and a D:D column with the same formula (but "denied" instead of approved) and add a conditional formatting with some conditions to the A1 cell:
1) if the A1 cell is equal to the correspondant C1, then color it green (excel will give you "$C$1", remove the $ marks on the number);
2) if the A1 cell is equal to the correspondant D1, then color it red (excel will give you "$D$1", remove the $ marks on the number);
Then save the conditions; now copypaste (special paste: format) the cell on all C column. At the end, hide column C and D for a better graphic result. Buon lavoro!
IMHO, it's easier to apply to column A green rule
=$B1="approved"
and red rule
=$B1="denied"
Please see second sheet in attached
- Samuele MerolaCopper ContributorThank you very much!