find a cell, jump to next roll and clear all cells

  • Thread starter Thread starter jigsaw2
  • Start date Start date
J

jigsaw2

Hello,

Does anyone know how to write a macro to find a specific text, then say
go to next row and clear everything below.

Thanks
Lai
 
Lai

without a bit more detailed information, the simple answer is yes, I'm sure
lots of people know how to write a macro to do this. Try something similar
to the following:

Sub DeleteRowsBelowXXX()
Dim SearchRow As String
SearchRow = Cells.Find(What:="xxx", _
After:=ActiveCell, _
LookIn:=xlFormulas, _
LookAt:=xlPart, _
SearchOrder:=xlByRows, _
SearchDirection:=xlNext, _
MatchCase:=False).Row
Range("A" & SearchRow + 1 & ":A65536").EntireRow.Delete
End Sub

Regards

Trevor
 
Back
Top