Please Note: This article is written for users of the following Microsoft Excel versions: 2007, 2010, 2013, and 2016. If you are using an earlier version (Excel 2003 or earlier), this tip may not work for you. For a version of this tip written specifically for earlier versions of Excel, click here: Using a Different Footer on Secondary Pages.

Using a Different Footer on Secondary Pages

by Allen Wyatt
(last updated May 7, 2016)

2

When creating a worksheet that will eventually be printed, you may want to use a different footer on the first page of your document than you do on the subsequent pages. There is no way to do this directly in Excel, but you can use a macro to accomplish the task.

The following macro will set the footers for a worksheet depending on what is being printed. Actually, it sets the footers for the first page, and then prints that page. Then it sets the footers for the other pages, and prints them.

Sub PrintSheet()
    Dim sP1Left As String
    Dim sP1Center As String
    Dim sP1Right As String
    Dim sP2Left As String
    Dim sP2Center As String
    Dim sP2Right As String

    ' Define first-page footers
    sP1Left = "First page left"
    sP1Center = "First page center"
    sP1Right = "First page right"

    ' Define second-page footers
    sP2Left = "Second page left"
    sP2Center = "Second page center"
    sP2Right = "Second page right"

    ' Set up and print first page
    With ActiveSheet.PageSetup
        .LeftFooter = sP1Left
        .CenterFooter = sP1Center
        .RightFooter = sP1Right
    End With
    ActiveSheet.PrintOut 1, 1

    ' Set up and print other pages
    With ActiveSheet.PageSetup
        .LeftFooter = sP2Left
        .CenterFooter = sP2Center
        .RightFooter = sP2Right
    End With
    ActiveSheet.PrintOut 2
End Sub

To use the macro, all you need to do is change the footer definitions. Change the variable values in the "Define first-page footers" area and the "Define second-page footers" area in order to get just the output you want.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (11287) applies to Microsoft Excel 2007, 2010, 2013, and 2016. You can find a version of this tip for the older menu interface of Excel here: Using a Different Footer on Secondary Pages.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He  is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Understanding Point Sizes

Points are the common unit of measure for typefaces in the printing industry. They are also used quite often in Word. ...

Discover More

Word Operates Backwards

What is someone to do when all of a sudden Word starts displaying text from right to left instead of left to right? The ...

Discover More

Reversing Type

Most text appears black on white, not white on black. If you want to change this so that your type is reversed, here's a ...

Discover More

Save Time and Supercharge Excel! Automate virtually any routine task and save yourself hours, days, maybe even weeks. Then, learn how to make Excel do things you thought were simply impossible! Mastering advanced Excel macros has never been easier. Check out Excel 2010 VBA and Macros today!

More ExcelTips (ribbon)

Roman Numerals for Page Numbers

Yes, Excel can work with Roman numerals, and it even provides a worksheet function that converts to them. How you use ...

Discover More

Specifying Date Formats in Headers

Don't like the default date format used by Excel when you place the date in a header or footer? You can use a macro to ...

Discover More

Dynamic Headers and Footers

Do you want to change the headers and footers that appear on different pages of your printout? Here's how you can get ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is three more than 8?

2017-06-13 13:07:48

Dennis Costello

I haven't run the experiments, but with all these tips that involve multiple <worksheet>.Print operations I'm concerned that each one might be a separately queued print job, which gives rise to two concerns:
- On corporate, shared printers, you'd get one or more, separate flag pages for each .Print operation
- If you were trying to do duplex printing, for this tip in particular, page 2 would start a new job on a new piece of paper, instead of being on the back side of page 1.


2016-05-07 17:12:12

Paul

Excel 2010 onwards does (I think) let you have a different first page header/footer and/or different odd and even header/footers.

Click File, choose Print and click
Page Setup at the bottom of the Print settings. On the Header/Footer tab you can now choose the options you require.

Click the Custom Header or Custom Footer button to see tabs for the different headers/footers you have opted for.


This Site

Got a version of Excel that uses the ribbon interface (Excel 2007 or later)? This site is for you! If you use an earlier version of Excel, visit our ExcelTips site focusing on the menu interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.