Sub Imprimer()
Dim col As Variant, coldeb%, colfin%
With ActiveSheet
With .PageSetup
.PrintTitleColumns = "$A:$G" 'colonnes à répéter à gauche
col = Application.Match([A1], Cells(3, "H").Resize(, Columns.Count - 7), 0)
If IsError(col) Then Exit Sub
col = col + 7
coldeb = col - 2
If coldeb < 8 Then coldeb = 8
colfin = col + 2
If Cells(3, colfin) = "" Then colfin = colfin - 1
If Cells(3, colfin) = "" Then colfin = colfin - 1
.PrintArea = Range(Columns(coldeb), Columns(colfin)).Address 'zone d'impression
.Zoom = False 'indispensable
.FitToPagesWide = 1 '1 page en largeur
.FitToPagesTall = 1 '1 page en hauteur
.Orientation = xlLandscape 'Paysage
End With
.PrintPreview 'pour tester
'.PrintOut 'pour imprimer ôter l'apostrophe
End With
End Sub