I use Excel 2007.
I wish to delete row that contain Various contents
I have tryed following code. It stop on what = "Fail" or "Loggoff"
sub Fail()
Dim rng as Range
Dim what As String
what = "Fail" or "Loggoff"
Do
Set rng = ActiveSheet.UsedRange.Find(what)
If rng Is Nothing then
Exit Do
Else
Rows(rng.Row).Delete
End If
Loop
End sub
Thanks Erik
I wish to delete row that contain Various contents
I have tryed following code. It stop on what = "Fail" or "Loggoff"
sub Fail()
Dim rng as Range
Dim what As String
what = "Fail" or "Loggoff"
Do
Set rng = ActiveSheet.UsedRange.Find(what)
If rng Is Nothing then
Exit Do
Else
Rows(rng.Row).Delete
End If
Loop
End sub
Thanks Erik