do this when cell empty vba code example
Example 1: excel vba check cell not empty
'VBA to check if cell A1 has a value.
'Two different ways...
MsgBox Not IsEmpty([A1])
MsgBox Not Len([A1]) = 0
Example 2: excel vba set cell value to empty
Range("A1:D5").ClearContents