The following code does not run across all of my worksheets. It seems to just run the same code on the first tab multiple times. Can someone help me fix this? My best guess is that that the ActiveCell member is causing this issue, but I do not know how to fix this.
Code:
Sub DeleteRowsfromEachSheet()
Dim wk As Worksheet
For Each wk In ThisWorkbook.Worksheets
Dim Counter As Long
Range("B1").Select ' Start at B1
For Counter = 1 To 100
If ActiveCell.Value Like "*Allocated Operating Exp OE Comp and Other Excl Stock Comp*" Then
ActiveCell.EntireRow.Delete ' Delete Row
Else
ActiveCell.Offset(1, 0).Select ' Move down a row
End If
Next Counter
Next wk
End Sub