Private Sub Worksheet_Change(ByVal Target As Range)
onglet = ActiveSheet.Name 'Ligne ajoutée pour éviter qu'en validant avec la touche entrée on descend d'une cellule
cellule = Target.Address
If Target.Address = "$H$6" Or Target.Address = "$I$5" Or Target.Address = "$J$5" Then
Application.ScreenUpdating = False
If Range("H6") = "All" Then
Range("H11").AutoFilter
Else
Range("A11:Q3000").AutoFilter
Range("A11:Q3000").AutoFilter Field:=8, Criteria1:=Range("H6"), VisibleDropDown:=False
If [I5] <> "" And [J5] <> "" Then
Date1 = Month([I5]) & "/" & Day([I5]) & "/" & Year([I5])
Date2 = Month([J5]) & "/" & Day([J5]) & "/" & Year([J5])
Range("A11:Q3000").AutoFilter Field:=1, Criteria1:=">=" & Date1, _
Operator:=xlAnd, Criteria2:="<=" & Date2, VisibleDropDown:=False
End If
End If
End If
End Sub