Bonjour,
Le code de ton fichier ne correspondait aux plages de ton fichier.
Remarque que j'en enlevé "Header:=xlGuess," il n'est pas nécessaire de mentionner qu'il y a "entête".
À titre d'exemple ... à ajuster au besoin.
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If Not Application.Intersect(Target, Range("A5:A31")) Is Nothing Then
Range("A5:H31").Sort Key1:=Cells(1, 1), Order1:=xlAscending, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom
End If
If Not Application.Intersect(Target, Range("A47:A58")) Is Nothing Then
Range("A47:H58").Sort Key1:=Cells(1, 1), Order1:=xlAscending, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlTopToBottom
End If
End Sub
ric