Datasheet

9
Chapter 1: Using Macros and Form Controls
8
9
0
A macro you create in Excel can have a relative, an absolute, or a mixed reference. If you use a relative reference,
Excel performs the macro based on a relative location. For example, suppose you move up two cells from cell A3 to
cell A1 when creating your macro. When you run your macro, if you are in cell C3, Excel moves up two cells from
cell C3 to cell C1. If you use an absolute reference, however, Excel performs the macro based on the exact cell
addresses. For example, suppose again that you move up two cells from cell A3 to A1. When you run your macro, if
you are in cell C3, Excel moves from there to the cells you used when you recorded your macro. That is, Excel moves
from cell A3 to cell A1.
By default, Excel creates macros with an absolute reference. To create a macro with a relative reference, click Use
Relative References in the Code group on the Developer tab to toggle the relative reference option on. To create a
macro with both a relative and an absolute reference — a mixed reference — toggle the Use Relative References
button on and off as needed as you create your macro.
9 Click the Developer tab.
Alternatively, click the Stop Recording
button on the status bar and skip Step 10.
0 Click Stop Recording.
Excel stops recording your macro.
Your macro is ready for you to use.
8 Perform the steps you want to record.
Note: This example changes the number
format using the following steps. Click the
Home tab. Click the Number Group launcher.
Click Accounting. Set Decimal Place to 0.
Select $ as Symbol. Click OK.
03_591598-ch01.indd 903_591598-ch01.indd 9 6/11/10 1:41 PM6/11/10 1:41 PM