EXCEL VBA PROGRAMMING
Preface to Excel VBA programming
You will be ready for engineering programming after completing this tutorial. Chapter twelve concludes the first part of this tutorial with a bubble sort sample program. It combines many of the elements described in the first part of the manual. It includes, variables, loops, if statements, lists, and functions.
Table of Contents
Chapter 1 - Introduction to VBA programming
- 1.1 Excel screen
- 1.2 Starting out in Worksheet
- 1.3 Saving your work from Worksheet
- 1.4 Syntax for general form of programs
- 1.5 Visual Basic Editor screen
- 1.6 Two basic programs
- 1.7 Basic program parts
- 1.8 Variables
- 1.9 Arrays
Chapter 2 - Excel VBA Loops
- 2.1 For next loop
- 2.2 Do while loop
- 2.3 Comments
- 2.4 Endless loop
- 2.5 Do until loops
Chapter 3 - If statements
- 3.1 If-then-else
- 3.2 If -then
- 3.3 Nested if-then-else
- 3.4 If-elseif-else
- 3.5 Select case statements
Chapter 4 - VBA functions vs. worksheet formulas and functions
- 4.1 Excel worksheet formulas and functions
- 4.2 Custom VBA functions
- 4.3 Brief subroutine discussion
- 4.4 Example custom VBA function
Chapter 5 - VBA subroutines and functions
- 5.1 Calling a subroutine and a function
- 5.2 Example program calling a subroutine and function with arguments
- 5.3 Duplicate functions in the code window
Chapter 6 - Read data from and write data to a worksheet from VBA
- 6.1 Reading and writing from single cells
- 6.2 Reading and writing from a list of values
Chapter 7 - Operators
Chapter 8 - Built-in VBA functions
Chapter 9 - Built-in VBA functions: exponential form of decimals, log base 10, log base e, trigonometric functions, format, round
- 9.1 Exponential forms
- 9.2 Base 10 and natural logarithms
- 9.3 Trigonometric functions
- 9.4 Format numbers
- 9.5 Round
Chapter 10 - Debugging
Chapter 11 - Running subroutines from the worksheet
- 11.1 Macro dialog box
- 11.2 Creating a worksheet button
- 11.3 Computer Lockups
Chapter 12 - More example VBA programs
- 12.1 Passing by value or by reference
- 12.2 Program calling a subroutine with variables and an array as arguments
- 12.3 Local and public variables in functions and subroutines
- 12.4 Ascending bubble sort of array of values with public variables
Chapter 13 - Worksheet functions and formulas
- 13.1 Built-in worksheet functions
- 13.2 Worksheet formula example
- 13.3 Worksheet formula from worksheet data
- 13.4 Worksheet formula from named cells
- 13.5 Named cells and subroutines
- 13.6 Named cells and custom VBA functions
Chapter 14 - Review questions