根据放置的其他列更改列的颜色 [英] Changing Color of a column based on other column in put
问题描述
我有一个包含颜色"和进度间隔"列的表,我想根据颜色列"中的单元格更改进度间隔"列中的单元格颜色.例如,如果单元格D2表示绿色,则E2将被填充为绿色.
条件格式
如果 Progress Interval
在 E
列中,请选择从 E2
到最后一个单元格的范围,例如 E20
并转到 Format>>条件格式
选择公式为
,然后复制/粘贴以下公式:
= D2 =绿色"
现在单击 Format
,然后单击 Patterns
选项卡,然后选择所需的绿色并更改其他任何内容( Font,Border ).完成后,单击确定".
现在,您可以单击添加"以添加另一个条件,并对黄色"执行相同的操作.完成后,单击确定".
如果要排除不包含数据的单元格,请使用
= AND(E2<>",D2 ="Green")
现在仅突出显示 E
列中包含数据的单元格.
I have a table that has Color and Progress Interval Columns, I wanted to change the cell color in Progress Interval Column based on cell in Color Column. Example if Cell D2 says Green, E2 will be filled with Green. Snap Shot From Table
Conditional Formatting
If Progress Interval
is in column E
, select the range from E2
to the last cell e.g. E20
and go to Format >> Conditional Formatting
choose Formula is
and copy/paste the following formula:
=D2="Green"
Now click Format
and click on the Patterns
tab and choose the green color you need and change anything else (Font, Border
). When done click OK.
Now you can click Add to add another condition and do the same for Yellow. When finished click OK.
If you want to exclude cells that contain no data use:
=AND(E2<>"",D2="Green")
Now only cells in the E
column containing data will be hightlighted.
这篇关于根据放置的其他列更改列的颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!