空数据单元验证 [英] Empty data cell validation

查看:52
本文介绍了空数据单元验证的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在单元格上添加验证,以在创建新数据记录后检查单元格是否不为空?类似于必填字段.

How can I add validation on cell, that checks if the cell is not empty after creating new data record? Something like mandatory fields.

推荐答案

我认为这是不可能的(按照我认为您的要求).从此处:

I think this is not possible (in the way I think you are requesting). From here:

如果将数据验证应用于包含数据的单元格,则在修改数据之前不会应用规则.

If data validation is applied to cells containing data, rules won't be applied until the data is modified.

实际上并没有说不,这是不可能的",但是我认为可以反过来解释为没有修改,没有验证触发器"-我假设您的单元格开始是空的(尽管我认为是空白的)实际上没有任何区别.

That does not actually say "No, it is not possible" but I think can be inverted as, "No modification, no trigger for validation" - and I'm assuming your cells start off empty (though for blanks I think it does not actually make any difference).

我建议考虑替代方法,可能是对空单元格进行条件格式化(对于 Cell is empty 有特殊规定),该公式用于计算应填充范围内空白单元格的数量(因为提到记录,您可能更希望标记行而不是每个空白单元格),或者诉诸脚本.

I suggest considering alternatives, possibly conditional formatting of cells that are empty (there is specific provision for Cell is empty), a formula to count the number of blanks cells in a range that should be populated (since you mention records you might prefer a row to be flagged rather than each individual blank cell), or resorting to a script.

这篇关于空数据单元验证的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆