Sub Préparer_Impression()
Dim c As Range, Décaler As Boolean
If F03_Devis.PageSetup.Pages.Count > 1 Then
With F03_Devis.[Plage_CTRL]
.Borders(xlEdgeLeft).LineStyle = xlContinuous
.Borders(xlEdgeRight).LineStyle = xlContinuous
.Borders(xlEdgeTop).LineStyle = xlContinuous
.Borders(xlEdgeBottom).LineStyle = xlContinuous
.Borders(xlInsideHorizontal).LineStyle = xlNone
.Rows(1).Borders(xlEdgeBottom).LineStyle = xlContinuous
For Each c In .Columns(1).Cells
If c.EntireRow.PageBreak <> xlPageBreakNone Then
F03_Devis.Cells(c.Row - 1, 1).Resize(1, 9).Borders(xlEdgeBottom).LineStyle = xlContinuous
F03_Devis.Cells(c.Row, 1).Resize(1, 9).Borders(xlEdgeTop).LineStyle = xlContinuous
End If
Next
End With
With F03_Devis.[Récap]
Décaler = False
i = 0
For Each c In .Columns(1).Cells
i = i + 1
If c.EntireRow.PageBreak <> xlPageBreakNone Then Décaler = True: Exit For
Next
If Décaler Then .Rows(1).EntireRow.Resize(i).Insert Shift:=xlDown, CopyOrigin:=xlFormatFromLeftOrAbove
End With
End If
End Sub