Make Your Own Customized Excel 2013 Header or Footer
Occasionally, you may want to insert information in Excel 2013 that is not available in the stock list boxes or in an arrangement that Excel doesn’t offer in the readymade headers and footers.
For those times, you need to use the command buttons that appear in the Header & Footer Elements group of the Design tab on the Header & Footer Tools contextual tab. These command buttons enable you to blend your own information with that generated by Excel into different sections of the custom header or footer you’re creating.
The command buttons in the Header & Footer Elements group include
Page Number: Click this button to insert the &[Page] code that puts in the current page number.
Number of Pages: Click this button to insert the &[Pages] code that puts in the total number of pages.
Current Date: Click this button to insert the &[Date] code that puts in the current date.
Current Time: Click this button to insert the &[Time] code that puts in the current time.
File Path: Click this button to insert the &[Path]&[File] codes that put in the directory path along with the name of the workbook file.
File Name: Click this button to insert the &[File] code that puts in the name of the workbook file.
Sheet Name: Click this button to insert the &[Tab] code that puts in the name of the worksheet as shown on the sheet tab.
Picture: Click this button to insert the &[Picture] code that inserts the image that you select from the Insert Picture dialog box that shows the contents of the my Pictures folder on your computer by default.
Format Picture: Click this button to apply the formatting that you choose from the Format Picture dialog box to the &[Picture] code that you enter with the Insert Picture button without adding any code of its own.
To use these command buttons in the Header & Footer Elements group to create a custom header or footer, follow these steps:
Put your worksheet into Page Layout view by clicking the Page Layout View button on the Status bar or by clicking View→Page Layout view on the Ribbon or pressing Alt+WP.
In Page Layout view, the text Click to Add Header appears centered in the top margin of the first page and the text Click to Add Footer appears centered in the bottom margin.
Position the mouse pointer in the top margin to create a custom header or the bottom margin to create a custom footer and then click the pointer in the left, center, or right section of the header or footer to set the insertion point and left-align, center, or right-align the text.
When Excel sets the insertion point, the text Click to Add Header and Click to Add Footer disappears and the Design tab on the Header & Footer Tools contextual tab becomes active on the Ribbon.
To add program-generated information to your custom header or footer (such as the filename, worksheet name, current date, and so forth), click the information’s corresponding command button in the Header & Footer Elements group.
Excel inserts the appropriate header/footer code preceded by an ampersand (&) into the header or footer. These codes are replaced by the actual information (filename, worksheet name, graphic image, and the like) as soon as you click another section of the header or footer or finish the header or footer by clicking the mouse pointer outside of it.
(Optional) To add your own text to the custom header or footer, type it at the insertion point.
When joining program-generated information indicated by a header/footer code with your own text, be sure to insert the appropriate spaces and punctuation. For example, to have Excel display Page 1 of 4 in a custom header or footer, you do the following:
Type the word Page and press the spacebar.
Click the Page Number command button and press the spacebar again.
Type the word of and press the spacebar a third time.
Click the Number of Pages command button.
This inserts Page &[Page] of &[Pages] in the custom header (or footer).
(Optional) To modify the font, font size, or some other font attribute of your custom header or footer, drag through its codes and text, click the Home tab, and then click the appropriate command button in the Font group.
In addition to selecting a new font and font size for the custom header or footer, you can add bold, italic, underlining, and a new font color to its text with the Bold, Italic, Underline, and Font Color command buttons on the Home tab.
After you finish defining and formatting the codes and text for your custom header or footer, click a cell in the Worksheet area to deselect the header or footer area.
Excel replaces the header/footer codes in the custom header or footer with the actual information, while at the same time removing the Header & Footer Tools contextual tab from the Ribbon.
Here is a custom footer added to a spreadsheet in Page Layout view. This custom footer blends text, Preliminary Client List, with a program-generated sheet name, date, and time information, and uses all three sections: left-aligned page information, centered Preliminary Client List text, and right-aligned current date and time.