有人知道这段代码有什么问题吗?当 A 到 F 列为空时,它应该删除行。谢谢
Sub range_reporter()
Dim n As Long
Dim nLastRow As Long
Dim nFirstRow As Long
ActiveSheet.UsedRange
Set r = ActiveSheet.UsedRange
nLastRow = r.Rows.Count + r.Row - 1
nFirstRow = r.Row
For n = nLastRow To nFirstRow Step -1
If Cells(n, "A") & Cells(n, "B") & Cells(n, "C") & Cells(n, "D") & Cells(n, "E") & Cells(n, "F") = "" Then
Cells(n, "A").EntireRow.Delete
End If
Next n
End Sub