Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)
If Sh.Name <> "Menu" Then Exit Sub
If Intersect(Target, Sh.[C4]) Is Nothing Then Exit Sub
Dim derlig&
Workbook_Open 'RAZ
On Error Resume Next 'si la feuille n'existe pas
With Sheets(CStr(Sh.[C4]))
.Visible = xlSheetVisible
With .Range("A7:Q" & .Rows.Count)
.Sort .Columns(4), xlDescending, Header:=xlNo 'tri sur colonne D
.Borders(xlInsideHorizontal).LineStyle = xlNone 'effacement des bordures horizontales
derlig = .Find("*", , xlValues, , xlByRows, xlPrevious).Row
.Resize(derlig - 6).Borders(xlInsideHorizontal).Weight = xlHairline 'bordures horizontales
.Parent.PageSetup.PrintArea = .EntireColumn.Resize(derlig).Address 'zone d'impression
End With
Application.Goto .[A1], True 'cadrage
End With
End Sub