About Running a Macro (VBA/Active)

Running a macro executes the macro code within the context of the current AutoCAD session.

The current active drawing is considered to be the open drawing that has the focus when macro execution begins. All VBA references to the ThisDrawing object will refer to the current active drawing for macros in global projects. For macros in embedded projects, the ThisDrawing object always refers to the drawing in which the macro is embedded.