Printing odd/even pages

J

JKiser

In Excel XP, is there a way to print just the odd numbered
pages or just the even numbered pages?

Thanx
 
R

Ron de Bruin

You can use a macro

Sub test()
Dim Totpage As Integer
Dim a As Integer
Totpage = Application.ExecuteExcel4Macro("GET.DOCUMENT(50)")
For a = 2 To Totpage Step 2
ActiveSheet.PrintOut From:=a, To:=a, _
Copies:=1, Collate:=True
Next
End Sub

Change
For a = 2 To Totpage Step 2
to
For a = 1 To Totpage Step 2 for the other pages


Or this one from Gord with inputbox

Sub PrintDoubleSided()
Dim Totalpages As Long
Dim pg As Long
Dim oddoreven As Integer
On Error GoTo enditt
Totalpages = ExecuteExcel4Macro("Get.Document(50)")
oddoreven = InputBox("Enter 1 for Odd, 2 for Even")
For pg = oddoreven To Totalpages Step 2
ActiveWindow.SelectedSheets.PrintOut from:=pg, To:=pg
Next pg
enditt:
End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top