1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
|
Sub Macro3()
'
Dim Str_macro As String
Str_macro = "PAGE.SETUP("
Str_macro = Str_macro & Chr(34) & Format(Date, "dd mmmm yyyy") & Chr(34) 'en_tête
Str_macro = Str_macro & ", ""&L &D &C &F &R Page &P""" 'pied_pg
Str_macro = Str_macro & ", 0.25, 0.25, 0.75, 0.75" 'marges gauche,droite,haut,bas en pouce
Str_macro = Str_macro & ", $1:$2" 'En-tête de ligne et de colonne
Str_macro = Str_macro & ", FALSE" 'quadrillage
Str_macro = Str_macro & ", TRUE, FALSE" 'centrage horizontal,vertical
Str_macro = Str_macro & ", 2" 'orientation - 1=portrait / 2=paysage
Str_macro = Str_macro & ", 8" 'papier - 8=A3 / 9=A4
Str_macro = Str_macro & ", FALSE" 'échelle sur une seule page
Str_macro = Str_macro & ", {1,#N/A}" 'échelle : 1 page en largeur, pas de contrainte en hauteur
'Str_macro = Str_macro & ", 100" 'no_pg
Str_macro = Str_macro & ", Auto" 'ordre_impression
Str_macro = Str_macro & ", FALSE" 'cellules en noir & blanc
Str_macro = Str_macro & ", 600" 'qualité
Str_macro = Str_macro & ", 0.30, 0.30" 'marge_en_tête ,marge pied de page
Str_macro = Str_macro & ", FALSE" 'annotations
Str_macro = Str_macro & ", FALSE" 'brouillon
Str_macro = Str_macro & ")"
Application.ExecuteExcel4Macro (Str_macro)
MsgBox "fini"
End Sub |
Partager