且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何检查一个单元格是否为空?

更新时间:2023-11-25 09:17:46

我想你应该看看 Range(你的范围)。specialcells(xlCellTypeBlanks)。这是循环通过空单元格的最快方法。

如果需要循环使用非空白单元格,可以检查单元格是否相交空白单元格范围。

I think you should have a look at Range("your range").specialcells(xlCellTypeBlanks). This is the fastest way to loop through empty cells.
If you need to loop on non blank cells, you can check if your cell Intersect the empty cells range.