As an illustration of the conditions, I have the code below that modifies a value in the H2–K2 range. Nevertheless, I need it to iterate over each of the coloured cells.
Choose all of the coloured cells to set the range, then compare it to the numbers in the "Product" column.
But, each time the macro is executed, the range of coloured cells will differ, and the value to be verified (Column P) won't always be in Column P.
No change has to be performed to the cell if the value does not satisfy any of the requirements in the If statement.
Any help would be much appreciated
Sub Turn_Live_Digital()
If Range("p2").Value = "ADSHEL LIVE" Or _
Range("p2").Value = "ASDA LIVE" Or _
Range("p2").Value = "CC DIGITAL MALLS" Or _
Range("p2").Value = "CCB DIGITAL" Or _
Range("p2").Value = "MALLS XL" Or _
Range("p2").Value = "SAINSBURYS LIVE" Or _
Range("p2").Value = "SOCIALITE" Or _
Range("p2").Value = "STATION LIVE" Or _
Range("p2").Value = "STORM DIGITAL" _
Then
Range("h2:k2").Value = "Digital"
End If
End Sub
I wouldn't know where to start