Before you start Microsoft Office Excel, you can make sure that a specific workbook (workbook: A spreadsheet program file that you create in Excel. A workbook contains worksheets of rows and columns in which you can enter and calculate data.) or a workbook template or worksheet template (template: A workbook that you create and use as the basis for other similar workbooks. You can create templates for workbooks and worksheets. The default template for workbooks is called Book.xlt. The default template for worksheets is called Sheet.xlt.) that has custom settings opens automatically when you start Excel. If you no longer need a specific workbook to open, you can stop it from being opened when you start Excel.
If a workbook that is opened when you start Excel contains automatic macros, such as Auto_Open, those macros will run when the workbook opens. If needed, you can prevent them from running automatically when you start Excel.
Tip You can also customize the way that Excel starts by adding command-line switches and parameters to the startup command.
For more information, see Command-line switches for Excel.
In this article
Automatically open a specific workbook when you start Excel
To automatically open a specific workbook when you start Excel, you can place that workbook in the XLStart folder, or you can use an alternate startup folder (alternate startup folder: A folder in addition to the XLStart folder that contains workbooks or other files that you want to be opened automatically when you start Excel and templates that you want to be available when you create new workbooks.) in addition to the XLStart folder.
Place a workbook in the XLStart folder
Any workbook, template, or workspace file (workspace file: A file that saves display information about open workbooks, so that you can later resume work with the same window sizes, print areas, screen magnification, and display settings. A workspace file doesn't contain the workbooks themselves.) that you place in the XLStart folder is automatically opened when you start Excel. This XLStart folder was created when you installed Excel, and is usually located in one of the following places.
- In Windows Vista, the path to the XLStart folder is usually:
C:\Users\user name\AppData\Local\Microsoft\Excel\XLStart.
- In Microsoft Windows XP, the path to the XLStart folder is usually:
C:\Documents and Settings\user name\Application Data\Microsoft\Excel\XLStart.
Tip You can locate the exact path to the XLStart folder in the Trust Center.
How to locate the XLStart folder
- Click the Microsoft Office Button
, and then click Excel Options.
- Click Trust Center, and then under Microsoft Office Excel Trust Center, click Trust Center Settings.
- Click Trusted Locations, and then verify the path to the XLStart folder in the list of trusted locations.
Use an alternate startup folder
- Click the Microsoft Office Button
, click Excel Options, and then click the Advanced category.
- Under General, in the At Startup, open all files in box, type the full path of the folder that you want to use as the alternate startup folder.
Because Excel will try to open every file in the alternate startup folder, make sure that you specify a folder that contains only files that Excel can open.
Note If a workbook with the same name is in both the XLStart folder and the alternate startup folder, the file in the XLStart folder opens.
Top of Page
Stop a specific workbook from opening when you start Excel
Depending on the location of the workbook that is automatically opened when you start Excel, do any of the following to make sure that the workbook no longer opens upon startup.
- If the workbook is stored in the XLStart folder, remove it from that folder.
- In Windows Vista, the path to the XLStart folder is usually:
C:\Users\user name\AppData\Local\Microsoft\Excel\XLStart.
- In Microsoft Windows XP, the path to the XLStart folder is usually:
C:\Documents and Settings\user name\Application Data\Microsoft\Excel\XLStart.
- If the workbook is stored in the alternate startup folder, do the following:
- Click the Microsoft Office Button
, click Excel Options, and then click the Advanced category.
- Under General, clear the contents of the At startup, open all files in box, and then click OK.
- In Windows Explorer, remove any icon that starts Excel and automatically opens the workbook from the alternate startup folder.
Tip You can also right-click that icon, click Properties, and then remove any references to the workbook on the Shortcut tab.
Top of Page
Automatically open a workbook template or worksheet template when you start Excel
You can save workbook settings that you frequently use in a workbook template, and then automatically open that workbook template every time that you start Excel.
- Do one of the following:
- To use a workbook template, create a workbook that contains the sheets, default text (such as page headers and column and row labels), formulas, macros (macro: An action or a set of actions that you can use to automate tasks. Macros are recorded in the Visual Basic for Applications programming language.), styles (style: A combination of formatting characteristics, such as font, font size, and indentation, that you name and store as a set. When you apply a style, all of the formatting instructions in that style are applied at one time.), and other formatting that you want to use in new workbooks that will be based on the workbook template.
- To use a worksheet template, create a workbook that contains one worksheet. On the worksheet, include the formatting, styles, text, and other information that you want to appear on all new worksheets that will be based on the worksheet template.
Settings that you can save in a workbook or worksheet template
- Cell and sheet formats.
- Page formats and print area (print area: One or more ranges of cells that you designate to print when you don't want to print the entire worksheet. If a worksheet includes a print area, only the print area is printed.) settings for each sheet.
- Cell styles.
- The number and type of sheets in a workbook.
- Protected and hidden areas of the workbook. You can hide sheets, rows, and columns and prevent changes to worksheet cells.
- Text you want to repeat, such as page headers and row and column labels.
- Data, graphics, formulas, charts, and other information.
- Data validation settings.
- Macros, hyperlinks (hyperlink: Colored and underlined text or a graphic that you click to go to a file, a location in a file, a Web page on the World Wide Web, or a Web page on an intranet. Hyperlinks can also go to newsgroups and to Gopher, Telnet, and FTP sites.), and ActiveX controls (ActiveX control: A control, such as a check box or button that offers options to users or runs macros or scripts that automate a task. You can write macros for the control in Microsoft Visual Basic for Applications or scripts in Microsoft Script Editor.) on forms.
- Workbook calculation options and window view options.
- Click the Microsoft Office Button
, and then click Save As.
- In the Save as type box, click Template.
- In the Save in box, select the folder where you want to store the template.
- In Windows Vista, the path to the XLStart folder is usually:
C:\Users\user name\AppData\Local\Microsoft\Excel\XLStart.
- In Microsoft Windows XP, the path to the XLStart folder is usually:
C:\Documents and Settings\user name\Application Data\Microsoft\Excel\XLStart.
- To create a custom workbook or worksheet template, make sure that the Templates folder is selected.
- In Windows Vista, the Templates folder is usually:
C:\Users\<user name>\AppData\Roaming\Microsoft\Templates.
- In Microsoft Windows XP, the Templates folder is usually:
C:\Documents and Settings\<user name>\Application Data\Microsoft\Templates.
- In the File name box, do one of the following:
- To create the default workbook template, type Book.
- To create the default worksheet template, type Sheet.
- To create a custom workbook or worksheet template, type the name that you want to use.
- Click Save.
- Click the Microsoft Office Button
, and then click Close.
Top of Page
Prevent automatic macros from running when you start Excel
Automatic macros (such as Auto_Open) that have been recorded in a workbook that opens when you start Excel will automatically run as soon as the workbook opens.
- To prevent macros from automatically running, hold down SHIFT while you start Excel.
Tip For more information about automatic macros, see Run a macro.
Top of Page