我尝试写一些代码,将删除其中的人物""或CHR(44)不以任何该行中的细胞上发现的任何行.
我已经做到这一点,但我正在努力,因为代码只搜索C列","但我需要它来搜索整个当前行.
我该如何更新?
Sub DeleteRows()
' Defines variables
Dim Cell As Range, cRange As Range, LastRow As Long, x As Long
' Defines LastRow as the last row of data based on column C
LastRow = ActiveSheet.Cells(Rows.Count, "C").End(xlUp).row
' Sets check range as C1 to the last row of C
Set cRange = Range("C1:C" & LastRow)
' For each cell in the check range, working from the bottom upwards
For x = cRange.Cells.Count To 1 Step -1
With cRange.Cells(x)
' …Run Code Online (Sandbox Code Playgroud)