The
Visual Basic for Applications Macros window enables
you to run, edit, or delete a macro.
About this task
To open the Macros window, use the Visual
Basic for Applications toolbar shortcut or select and use these selections
as needed:
- Macro Name contains the
name of the highlighted
macro in the Macro Box field. This field is blank if there
are no macros in the Macro Box.
- Macro
Box lists the available macros in
the Visual Basic for Applications project selected in the Macros
In box.
- Macros In lists the available
Visual Basic
for Applications projects that contain macros.
The
window contains the following buttons:
- Run runs
the selected macro.
To run a macro, highlight
a macro in the Macro box,
then click Run.
- Step Into highlights
the first line of the
macro and places the Current Execution Line Indicator.
- Edit opens the Code window with the selected
macro visible so you can modify your macro.
To
edit a macro, highlight the macro in the Macro box,
then click Edit.
- Create opens
a module in the Code window
so you can create a new macro.
To create
a macro, type in a new name in the Macro
Name field, then click Create.
Note: Since Visual Basic for Applications macros are contained
in modules, you must first create a module before creating your first
macro. If you have not yet created a module, the
Create button
is disabled. Modules cannot be created from the Macros window. You
must open the Visual Basic for Applications IDE to do so.
- Delete removes the selected macro from your
project.
To delete a macro, highlight a
macro in the Macro box,
then click Delete.
IBM® Rational® Rhapsody® Visual
Basic for Applications macros are saved automatically with your project.
When you load the project again, the macros you created are available.