Highlighting whole row in this macro

E

eastrivergraphics

Can I add something to this so that when the A1:A100 field is changed,
the whole row (A-L) is highlighted ColorIndex 6?

Dim x, cl

Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Target, Range("A1:A100")) Is Nothing Then Exit Sub
Target.Offset(0, 1) = x
Target.Interior.ColorIndex = 6
End Sub

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
x = ActiveCell.Value
End Sub
 
D

Dave Peterson

target.entirerow.resize(1,12).interior.colorindex = 6

or since the target is already in column A:
target.resize(1,12).interior.colorindex = 6
 
J

JE McGimpsey

One way:

Private Sub Worksheet_Change(ByVal Target As Range)
With Target
If Not Intersect(.Cells, Range("A1:A100")) Is Nothing Then
.Offset(0, 1) = x
.Resize(1, 12).Interior.ColorIndex = 6
End If
End With
End Sub
 
E

eastrivergraphics

Worked like a charm, thanks.

target.entirerow.resize(1,12).interior.colorindex = 6

or since the target is already in column A:
target.resize(1,12).interior.colorindex = 6
 
Top