Share via


Application.Macro Method

Project Developer Reference

Runs a macro.

Syntax

expression.Macro(Name)

expression   A variable that represents an Application object.

Parameters

Name Required/Optional Data Type Description
Name Optional String The name of the macro to run. If Name is omitted, the Macros dialog box appears.

Return Value
Boolean

Example
The following example runs a macro named "CheckShifts".

Visual Basic for Applications
  Sub RunMacro()
    Macro "CheckShifts"
End Sub

See Also