Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim Jour$, col&, Rng As Range
If IsDate(Target) Then
Jour = Day(Target)
With Sheets(MonthName(Month(Target)))
' .Activate
Set Rng = .Range("M3:AQ3")
col = Application.Match(Application.Index(Rng, 1, Jour), Rng, 0)
' .Cells(3, col + 12).Select
Columns("M:AQ").EntireColumn.Hidden = True
Columns(col + 12).EntireColumn.Hidden = False
With [M3:AQ3]
.Interior.Color = RGB(248, 249, 250)
.Font.ColorIndex = xlAutomatic 'couleur police noire
' If Intersect(ActiveCell, .Cells) Is Nothing Then Exit Sub
End With
With .Cells(3, col + 12)
.Interior.Color = RGB(76, 97, 112)
.Font.Color = RGB(255, 255, 255)
End With
End With
End If
End Sub