Bonjour à tous ,
Je reviens un peu vous embêter
Voila je souhaiterais imprimer les pages sélectionnées en mode paysage avec un ajustement à 1 page.
J'ai tapé ce code :
Private Sub CommandButton1_Click()
If CheckBox1.Value = True Then
Worksheets("Tableau comparatif").PageSetup.Orientation = xlLandscape
Application.Dialogs(Excel.XlBuiltInDialog.xlDialogPrinterSetup).Show
Sheets("Tableau comparatif").PrintOut
If CheckBox2.Value = True Then
Worksheets("Tableau IJSS").PageSetup.Orientation = xlLandscape
Application.Dialogs(Excel.XlBuiltInDialog.xlDialogPrinterSetup).Show
Sheets("Tableau IJSS").PrintOut
Unload Me
End If
End If
End Sub
Private Sub CommandButton2_Click()
Unload Me
End Sub
Tout fonctionne sauf le mode paysage et je ne sais pas comment rentrer le code " ajuster à une page"
Merci déja de vos réponses