Category Archives: Subs

Call Sub vs. Functions in VBA

Introduction In the MS Excel’s Visual Basic Editor, Sub is a statement, like a function fun(), that performs a specific task. A sub is a piece of code that performs a specific task and does not return a result. The purpose of a subroutine is to

All About Dim Statements in VBA

A variable is a named storage location in which you can store information while your macro/program is running.  Each variable has a unique name where the name can identify what type of variable it is by using standard naming conventions.  A variable can contain different

No Thumbnail

VBA Arrays and Userdefined Functions and Subs

In this article I will cover the following topics: Passing Arrays as Input Parameters to Functions and Subs ByRef Passing Arrays as Input Parameters to Functions and Subs ByVal Getting the dimension of the Input Array to Function or Sub: Declaring Functions With an Array