Datasheet

13
Chapter 1: Using Macros and Form Controls
6
5
Excel differentiates between macros listed in the Macro
dialog box by placing the name of the workbook that
contains the macros in front of the macro name. For
example, Excel lists a macro named
Sum_Expenses in
the Personal Macro Workbook as
PERSONAL.
XLSB!Sum_Expenses
. If the macro Sum_Cells exists
in both the Budget.xlsm and Expenses.xlsm workbooks,
Excel treats them as two different macros. The Macro
dialog box lists them as
Budget.xlsm!Sum_Cells
and
Expenses.xlsm!Sum_Cells.
Unless you have your macro settings set to enable all
macros, Excel checks all documents you open for
macros. See the section “Set Macro Security” for more
information. If you have files that you do not want Excel
to check, you can store them in a trusted location. Click
the Developer tab. Click Macro Security in the Code
group. The Trust Center appears. Click Trusted
Locations. The Trust Location pane appears. Click Add
New Location. The Microsoft Office Trusted Location
dialog box appears. Enter the path to the trusted
location. Click OK.
Excel runs the macro.
You can also run your macro
by pressing the shortcut key
you assigned when you
created the macro.
5 Click the name of the macro
you want to run.
6 Click Run.
03_591598-ch01.indd 1303_591598-ch01.indd 13 6/11/10 1:41 PM6/11/10 1:41 PM