选择列并根据VBA中的今天日期应用边框

时间:2014-02-10 10:32:08

标签: excel vba excel-vba

我有一系列包含各种列的数据。顶行包含一系列日期,我需要使用粗边框突出显示今天日期的列,然后为了突出显示使用工作表的任何一天的相关列?

日期格式为:2014年2月28日

谢谢你的帮助

1 个答案:

答案 0 :(得分:1)

您应该使用CONDITIONAL FORMATTING

1)选择您的数据范围(即A1:L13

enter image description here

2) 使用所选范围转到“条件格式 - >新规则..”

enter image description here

3)选择“使用公式...”规则类型,输入公式=A$1=TODAY(),其中A1左上角您的范围的单元格。选择所需的格式,然后按“确定”

enter image description here

<强>结果:

enter image description here