Run an Access Macro from Access VBA.
Syntax
DoCmd.RunMacro(MacroName, RepeatCount, RepeatExpression)
Key
MacroName The name of a macro in the current database.
RepeatCount The number of times to run the macro.
RepeatExpression
A numeric expression that's evaluated each
time the macro runsM. When it evaluates to False(0),
the macro will stop running.
Use macrogroupname.MacroName syntax for the MacroName argument to run a particular macro in a macro group.
Examples
'run the macro mcrPrintAppointments
DoCmd.RunMacro "mcrPrintAppointments"
“Run rabbit – run rabbit – Run! Run! Run!” ~ Flanagan and Allen.
Related:
RunDataMacro - Run a named data macro.