Add page numbers to multiple worksheets without changing page setu

G

Guest

I'm trying to add page numbers to multiple worksheets and It did work but
when I go to print, the page setup for all of my worksheets has been changed
to the setup of the first page or first worksheet in which I added the page
numbers. So I have pagebreaks in the middle of my documents. I've gone back
twice and changed the pagebreaks and this continues to happen.

Is there another way to have consectutive page numbers for the entire
workbook without the page setup changing for each worksheet?
 
G

Guest

alatona

To have consecutive page numbers for the entire wookbook "group" all the
worksheets first. There are several ways to do this but the one I use is:
select the first one (the one you want to be page one) then press "shift" and
select the last one. If you do not want to print all but still have
consecutive numbers for several worksheets select the first one and press
"ctrl" and individually select the worksheets you want to print. Be sure to
"UNGROUP" your worksheets when you are done.

Mike Rogers
 
G

Gord Dibben

If Mike's suggestion doesn't work for you, try this macro.

Sub Page_Nums()
With ActiveSheet.PageSetup
.CenterFooter = "Page &P of &N"
End With
ActiveWindow.SelectedSheets.PrintPreview 'PrintOut
End Sub


Gord Dibben MS Excel MVP
 

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