Bonjour
voici ma macro, elle insère un saut de page avant chaque "----------------------------------------- ". Comment faire pour insérer les saut de page avant ?
Sub SautDePage()
Dim c As Range
Dim i As Integer
With Feuil1 '
For Each c In .Range("A1:A" & [A65536].End(xlUp).Row)
If c.Value = "-----------------------------------------" Then
.HPageBreaks.Add Before:=c
i = i + 1
If i = 1026 Then Exit Sub
End If
Next
End With
End Sub
****
Merci pour votre aide.
voici ma macro, elle insère un saut de page avant chaque "----------------------------------------- ". Comment faire pour insérer les saut de page avant ?
Sub SautDePage()
Dim c As Range
Dim i As Integer
With Feuil1 '
For Each c In .Range("A1:A" & [A65536].End(xlUp).Row)
If c.Value = "-----------------------------------------" Then
.HPageBreaks.Add Before:=c
i = i + 1
If i = 1026 Then Exit Sub
End If
Next
End With
End Sub
****
Merci pour votre aide.