Sub testMAC()
Dim dict As New Scripting.Dictionary
dict.Add Key:=CDate("01/01/19"), Item:="event1"
dict.Add Key:=CDate("01/02/19"), Item:="event2"
dict.Add Key:=CDate("01/03/19"), Item:="event3"
dict.Add Key:=CDate("01/04/19"), Item:="event4"
dict.Add Key:=CDate("01/05/19"), Item:="event5"
dict.Add Key:=CDate("01/06/19"), Item:="event6"
If Cells(2, 9) = dict.Item(CDate("01/01/19")) Then
Cells.Range("B2:H2").Interior.ColorIndex = 16
Cells.Range("B2:H2").Value = 0
ElseIf Cells(2, 9) = dict.Item(CDate("01/02/19")) Then
Cells.Range("C2:H2").Interior.ColorIndex = 16
Cells.Range("C2:H2").Value = 0
ElseIf Cells(2, 9) = dict.Item(CDate("01/02/19")) Then
Cells.Range("D2:H2").Interior.ColorIndex = 16
Cells.Range("D2:H2").Value = 0
ElseIf Cells(2, 9) = dict.Item(CDate("01/03/19")) Then
Cells.Range("E2:H2").Interior.ColorIndex = 16
Cells.Range("E2:H2").Value = 0
ElseIf Cells(2, 9) = dict.Item(CDate("01/04/19")) Then
Cells.Range("F2:H2").Interior.ColorIndex = 16
Cells.Range("F2:H2").Value = 0
ElseIf Cells(2, 9) = dict.Item(CDate("01/02/19")) Then
Cells.Range("H2:H2").Interior.ColorIndex = 16
Cells.Range("H2:H2").Value = 0
End If
End Sub