Establishing Subroutines

A subroutine is a collection of VBA statements that, taken together, accomplish something. The term is a little unfortunate, implying that it is subordinate to something. The meaning is broader than that, though: A subroutine can be the main, top-level code in your project, or it can be a set of code that accomplishes some smaller task on behalf of the main code.

Providing the Subroutine's Basic Elements

In VBA, subroutines are stored in modules, and establishing a module is where it all starts. To establish a module you need to start the VBE.