Been a while since I have been on here or even coded in VBA, little rusty so need some help and start building a template toolbox for myself.
What i need the code to do is Look at a value in a column, then when it finds it, offset below and check to see what the next value is.
If it is "AVAIL" or "ENROUTE" then delete the entire row, then rinse and repeat.
Once i have the logic built for this one, i can modify the rest to do LOFF etc.
Here is the logic to the code I want, but of course its not working, could be as simple as I forget that i need to define something or im using the wrong suffix etc.
Sub work_filter() Dim LR As Long Application.ScreenUpdating = False For LR = Range("F" & Rows.Count).End(xlUp).Row To 2 Step -1 If Range("F" & LR).Value = "LON" Then ActiveCell.Offset(1, 0).Activate If ActiveCell.Value = "ENROUTE" Or "AVAIL" Then Rows(LR).EntireRow.Delete End If End If Next LR Application.ScreenUpdating = True End Sub