Here you go, this should fix it!
Sub highlight()
Dim rg As Range, c As Range
Dim firstAddress As String
Set rg = Range("L9", "L5000")
Application.ScreenUpdating = False
With rg
Set c = .Find("XXXXXXX", lookat:=xlWhole, LookIn:=xlValues)
If Not c Is Nothing Then
firstAddress = c.Address
Do
'column I is -3 columns from L
c.Offset(0, -3).Interior.ColorIndex = 4
'column I is -7 columns from L
c.Offset(0, -7).Interior.ColorIndex = 4
Set c = .FindNext(c)
If c Is Nothing Then Exit Do
Loop While c.Address <> firstAddress
End If
Application.ScreenUpdating = True
End With
End Sub
Let me know if this works for you
Bookmarks