D
Don Doan
Hi there,
I'm new to macro and I need some help with the program.
Basically, from cell B2 to B25...i want to look for the three character NHA
(in that order). If it's not there, erase the whole row. If it's there, keep
the row. There may be some characters or spaces before and after that word
NHA.
I a few lines in the program. If someone can help me modify it, that would
be great.
Sub Macro1()
Dim k As Long
For k = Cells(25, "b").End(xlUp).Row To 2 Step -1
If Cells(k, "b") <> "*NHA*" Then
Rows(k).EntireRow.Delete
End If
Next k
End Sub
I'm new to macro and I need some help with the program.
Basically, from cell B2 to B25...i want to look for the three character NHA
(in that order). If it's not there, erase the whole row. If it's there, keep
the row. There may be some characters or spaces before and after that word
NHA.
I a few lines in the program. If someone can help me modify it, that would
be great.
Sub Macro1()
Dim k As Long
For k = Cells(25, "b").End(xlUp).Row To 2 Step -1
If Cells(k, "b") <> "*NHA*" Then
Rows(k).EntireRow.Delete
End If
Next k
End Sub