You are here:

Excel/Excel margins and page numbers

Advertisement


Question
Damon,

I am using Microsoft Office Excel 97-2003.

I want to right justify the footer with the cells above the footer, and I want the page numbers to be correct.

When I reduce the right margin so it lines up, the footer's "page x of y" increases to "page x of (y+1)" as the nearest cells, which are unused, extend into the next page.  When I right justify it, the page number increases.  If I want the page number to be correct, it doesn't line up.  How can I line up the footer text with the contents of the cells above---and without the page number increasing?  I need both the line-up and the correct page number.

Sincerely,

B Stickney

Answer
Hi B,

Thank you for sending the screen capture, which helped.

I believe the problem is that you have set the right margin just slightly inside of column J.  This forces Excel to split the page vertically such that the right side of column J will print on a separate page, thus the increased page count.  To solve this problem make sure there is no data on the sheet to the right of column J. Then set the margin to the right (just slightly) of column J. That should cause the page count to drop to 1 and have the footer page number right justify to the margin, which is now the right side of column J.

Please let me know if this solves the problem.

Damon  
About Excel
This topic answers questions related to Microsoft Excel spreadsheet (or workbook) stand-alone or Mircrosoft Office Excel including Excel 2003, Excel 2007, Office 2000, and Office XP. You can get Excel help on Excel formulas(or functions), Excell macros, charting in Excel, advanced features, and the general use of Excel. This does not provide a general Excel tutorial nor the basics of using a spreadsheet. It provides specific answers to using Microsoft Excel only. If you do not see your Excel question answered in this area then please ask an Excel question here

Excel

All Answers


Answers by Expert:


Ask Experts

Volunteer


Damon Ostrander

Expertise

I have extensive experience with VBA programming in Excel 5 through Excel 2013. As a former aerospace engineer with a large aerospace corporation and consultant in a small defense technology services company, I have developed a wide range of applications in VBA, including simulations involving mixed-language programming, satellite orbit mechanics, graphics and animation, and real-time applications. I am interested in moderate to hard VBA-related questions only.

Experience

I have developed and taught several courses in Excel VBA programming and also VBA programming in Office 97, 2000, and 2007. I have developed a number of large technical applications in Excel VBA for use within the aerospace industry.

Education/Credentials
B.S. in Electrical Engineering and Computer Science, University of California, Berkeley.

©2016 About.com. All rights reserved.