18.11.2014 Views

Microsoft Office

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Part I<br />

Getting Started with Excel<br />

Creating a workbook template can eliminate repeating work. Assume that you create a monthly sales report<br />

that consists of your company’s sales by region, plus several summary calculations and charts. You can create<br />

a template file that consists of everything except the input values. Then, when it’s time to create your<br />

report, you can open a workbook based on the template, fill in the blanks, and be finished.<br />

You could, of course, just use the previous month’s workbook and save it with a different<br />

name. This is prone to errors, however, because you easily can forget to use the Save As command<br />

and accidentally overwrite the previous month’s file. Another option is to use the New From Existing<br />

option in the New Workbook dialog box. This command creates a new workbook from an existing one, but<br />

gives a different name to ensure that the old file is not overwritten,<br />

NOTE<br />

When you create a workbook that’s based on a template, the default workbook name is the template name<br />

with a number appended. For example, if you create a new workbook based on a template named Sales<br />

Report.xltx, the workbook’s default name is Sales Report1.xlsx. The first time that you save a<br />

workbook that is created from a template, Excel displays its Save As dialog box so that you can give the<br />

template a new name if you want to.<br />

A custom template is essentially a normal workbook, and it can use any Excel feature, such as charts, formulas,<br />

and macros. Usually, a template is set up so that the user can enter values and get immediate results. In<br />

other words, most templates include everything but the data, which is entered by the user.<br />

NOTE<br />

If your template contains macros, it must be saved as an Excel Macro-Enabled Template, with<br />

an XLTM extension.<br />

Saving your custom templates<br />

To save a workbook as a template, choose <strong>Office</strong> ➪ Save As and select Template (*.xltx) from the dropdown<br />

list labeled Save As Type. If the workbook contains any VBA macros, select Excel Macro-Enabled<br />

Locking Formula Cells in a Template File<br />

If novices will use the template, you might consider locking all the formula cells to make sure that the formulas<br />

aren’t deleted or modified.<br />

1. Press F5 to display the Go To dialog box.<br />

2. Click the Special button to display the Go To Special dialog box.<br />

3. Select Constants and click OK. This step selects all of the nonformula cells.<br />

4. Right-click any one of the selected cells and choose Format Cells from the shortcut menu. The<br />

Format Cells dialog box appears.<br />

5. In the Format Cells dialog box, click the Protection tab.<br />

6. Remove the check mark from the Locked check box.<br />

7. Click OK to close the Format Cells dialog box.<br />

8. Choose Review ➪ Changes ➪ Protect Sheet to display the Protect Sheet dialog box.<br />

9. Specify a password if you like and click OK.<br />

After you perform these steps, you can’t modify the formula cells — unless the sheet is unprotected.<br />

152

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!