Understanding VBA Function and Sub in Excel
Excel Visual Basic: A set of commands to perform a specific task is placed into a procedure, which can be a Function procedure or a Sub procedure (also known as functions and subroutines). The difference between a function and a sub in Excel VBA is that a function can return a value while a sub cannot. …