B
Brent
I am trying to write a program that will print out sheets depending on a
number in a cell on the first sheet. I want the pages printed to be
duplexed, but can only get them to come out single sided. any suggestions?
here is the code for the first for sheets.
Private Sub PRINT_PCW_Click()
Dim Vio_Num As Integer
Vio_Num = Sheets("Summary").Range("H13").Value
Sheets("Summary").PageSetup.PrintArea = "$A$1:$J$57"
Sheets("Summary").Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Sheets("Comphist").PageSetup.PrintArea = "$A$1:$L$35"
Sheets("Comphist").Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
If Vio_Num > 0 Then
Sheets("V1").PageSetup.PrintArea = "$A$1:$L$52"
Sheets("V1").Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Sheets("EB1").PageSetup.PrintArea = "$A$1:$H$32"
Sheets("EB1").Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
End If
End Sub
number in a cell on the first sheet. I want the pages printed to be
duplexed, but can only get them to come out single sided. any suggestions?
here is the code for the first for sheets.
Private Sub PRINT_PCW_Click()
Dim Vio_Num As Integer
Vio_Num = Sheets("Summary").Range("H13").Value
Sheets("Summary").PageSetup.PrintArea = "$A$1:$J$57"
Sheets("Summary").Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Sheets("Comphist").PageSetup.PrintArea = "$A$1:$L$35"
Sheets("Comphist").Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
If Vio_Num > 0 Then
Sheets("V1").PageSetup.PrintArea = "$A$1:$L$52"
Sheets("V1").Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
Sheets("EB1").PageSetup.PrintArea = "$A$1:$H$32"
Sheets("EB1").Select
ActiveWindow.SelectedSheets.PrintOut Copies:=1, Collate:=True
End If
End Sub