предположим, нужно выделить строки таблицы по параметру
Sub Raskraska()
Dim x, i&, j&, s$, TmpS$
Dim bu As Boolean
With Range("A1:B" & Cells(Rows.Count, 1).End(xlUp).Row + 1)
x = .Value
' .Resize(, 6).Interior.Color = xlNone
End With
For i = 2 To UBound(x)
s = x(i, 1) & "~" & x(i, 2)
If TmpS <> s Then
If bu Then Cells(j, 1).Resize(i - j, 6).Interior.Color = 15853276
j = i
TmpS = s
bu = Not bu
End If
Next i
End Sub