根据 1 个单元格的值给几个单元格着色

发布于 2025-01-17 06:10:11 字数 216 浏览 11 评论 0原文

我有一个每小时计划,其中员工会议的时间自动显示在另一张纸上。 我需要根据会议的长度用特定的颜色标记它。 前任。

"A1=0,5 则 A1 为蓝色 如果 A1=1 则 A1 和 A2 为蓝色 如果 A1=1,5 则 A1、A2、A3 为蓝色等。"

我只找到如何使用条件格式或 VBA 标记特定单元格的信息,但不知道如何将公式应用于整个桌子

I have a hourly plan where time of employees' meetings automatically appears from an other sheet.
I need it to be marked with specific color according to meeting's lenght.
Ex.

"A1=0,5 then A1 is blue
if A1=1 then A1 and A2 is blue
if A1=1,5 then A1, A2, A3 is blue and etc."

I only find info how to mark specific cell using conditional formating or VBA, but don't know how to apply formula to the whole table

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

瞄了个咪的 2025-01-24 06:10:11

条件格式

选择您想要应用此功能的范围,例如 A1:A10A1:J10(如果您希望此功能也适用于其他列)。

Home选项卡上选择Conditional Formatting >新规则
在“新格式”窗口中,选择“使用公式确定要设置格式的单元格”。
在下面的文本框中输入以下公式:

=A$1/0.5>=ROW()

按下面的格式按钮,然后在设置单元格格式窗口中选择填充选项卡。选择一种颜色并按 Ok 3 次。

Conditional Formatting

Select the range where you want this applied, e.g. A1:A10, or A1:J10 if you want this to work in the other columns, too.

On the Home tab select Conditional Formatting > New Rule.
In the New Formatting window select Use formula to determine which cells to format.
In the text box below enter this formula:

=A$1/0.5>=ROW()

Press the Format button below and in the Format Cells window select the Fill tab. Select a color and press Ok 3 times.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文