Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Page totals
Need to print multiple pages from several sheets. The first page may be a cover page and does not count in the total. I used the code to set the footer. The page numbers work but the total does not. If there are a total of three pages with the first being the cover I would like to see the first page after the cover say Page 1 of 2, but it displays page 1 of 31.
Sub TestFooter() mOffsetPageCounter = "-1" mrf = "&8Page " & "&P" & mOffsetPageCounter & " of " & "&N" & mOffsetPageCounter With Sheets("sheet1").PageSetup .RightFooter = mrf End With With Sheets("sheet2").PageSetup .RightFooter = mrf End With mfooter = Sheets("sheet2").PageSetup.RightFooter MsgBox mfooter End Sub |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Page totals
Your code worked fine for me.
-- Regards, Tom Ogilvy "Buckosmasher" wrote in message ... Need to print multiple pages from several sheets. The first page may be a cover page and does not count in the total. I used the code to set the footer. The page numbers work but the total does not. If there are a total of three pages with the first being the cover I would like to see the first page after the cover say Page 1 of 2, but it displays page 1 of 31. Sub TestFooter() mOffsetPageCounter = "-1" mrf = "&8Page " & "&P" & mOffsetPageCounter & " of " & "&N" & mOffsetPageCounter With Sheets("sheet1").PageSetup .RightFooter = mrf End With With Sheets("sheet2").PageSetup .RightFooter = mrf End With mfooter = Sheets("sheet2").PageSetup.RightFooter MsgBox mfooter End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
stop page totals creeping up page when scrolling | Excel Discussion (Misc queries) | |||
Sub Totals In Footer/End of the page? | Excel Discussion (Misc queries) | |||
PAGE TOTALS? | Excel Discussion (Misc queries) | |||
HOW DO I SETUP A PAGE IN EXCEL TO GIVE TOTALS TO ANOTHER PAGE | Excel Worksheet Functions | |||
print footer on every page (Totals on every page) | Excel Discussion (Misc queries) |