Excel 中针对日期的 IF 语句未显示正确的文本

Excel 中针对日期的 IF 语句未显示正确的文本

我在 Excel 中创建了一个公式,除了Due to expire部分

('General Training '!H3<$G$1-1003,"Due to Expire") 

它正在返回,FALSE有人可以给我指明正确的方向吗?

如果单元格为空白,则不执行任何操作。

如果日期H3小于 TODAY($G1) - 1003,则training required有效如果(H3)大于 TODAY($G1)“培训完成”也有效

=IF(ISBLANK('General Training '!H3),"",IF('General Training '!H3<$G$1-1097,"Training Required",IF('General Training '!H3<$G$1-1003,"Due to Expire",IF('General Training '!H3>$G$1,"Training Complete")))) 

答案1

您需要分离单元格H3-1003正在进行的计算H3<$G$1,然后-1003

将其括$G$1-1003在括号中,如下所示:

=IF(ISBLANK('General Training '!H3),"",IF('General Training '!H3<$G$1-1097,"Training Required",IF('General Training '!H3<($G$1-1003),"Due to Expire",IF('General Training '!H3>$G$1,"Training Complete")))) 

相关内容