Private
Sub
Worksheet_Change(
ByVal
Target
As
Range)
Dim
c
As
Range
For
Each
c
In
Target.Cells
If
c.Address(0, 0) =
"AB24"
Then
With
Cells(36, 9)
Select
Case
c.Value
Case
"A"
.Interior.Color = RGB(196, 215, 155)
Case
"B"
.Interior.Color = RGB(255, 255, 175)
Case
"C"
.Interior.Color = RGB(218, 150, 148)
Case
Else
End
Select
End
With
Else
Application.EnableEvents =
False
If
Not
Intersect(c, Range(
"G12:G20"
))
Is
Nothing
Then
If
c.Value = 0
Then
Cells(24, 28).Value =
"C"
Cells(36, 9).Interior.Color = RGB(218, 150, 148)
End
If
End
If
Application.EnableEvents =
True
End
If
Next
c
End
Sub