1. Macros in MS Excel – definition and application
Macros in MS Excel are introduced as a mechanism for automating repetitive tasks and standardizing selected activities in a workbook. The section defines what a macro is, outlines typical areas of use, and builds the context needed before recording, editing, and running VBA-based solutions.
2. Using Macros in MS Excel
Using macros in Excel means turning repeated worksheet activities into commands that can be executed consistently. Participants see how macros support everyday work organization, where they fit into the user workflow, and how they differ from manual operations performed directly in the sheet.
3. Opening a file with recorded macros
Files that contain recorded macros require a different handling model than standard workbooks. This part explains how to open such files correctly, what to look for when macros are present, and how to prepare the workbook for further inspection, editing, and controlled execution.
4. Opening and using the Visual Basic Editor
The Visual Basic Editor is the working environment for viewing, writing, and testing VBA code behind Excel actions. Participants learn how to open it, move within its interface, and use it in connection with recorded macros so they can shift from worksheet operations to code-based work.
5. Recording macros
Macro recording provides the first contact with automation by converting user actions in Excel into executable steps. Alongside the recording process itself, the section addresses opening files in a secure way and the basic security considerations connected with enabling and storing macros.
6. Relative and absolute references, changing the cell reference
Correct cell addressing determines whether a macro always points to the same place or adapts to the current position in a worksheet. The section explains relative and absolute references and shows how changing a reference affects copied actions, recorded steps, and later code behavior.
7. Analysis of Visual Basic code
Reading existing Visual Basic code helps identify what a macro does before any change is introduced. Attention is placed on following instructions, recognizing the role of individual lines, and understanding how the structure of code reflects actions performed earlier in Excel or the VBA editor.
8. Transforming recorded macros, editing and managing VBA code
Recorded macros become easier to maintain when their code is edited consciously in the VBA environment. This module covers comments, dialog boxes, toolbar layout, code coloring, enabling macros from the editor, using Debugger, keyboard shortcuts, and methods for archiving or moving code between files.
- comments,
- preparation of dialog boxes,
- enabling macros from the VBA editor,
- use of the Debugger tool,
- creating the VBA editor window – toolbars,
- the meaning of colors in code,
- archiving and transferring code,
- helpful keyboard shortcuts.
9. Creating your own button to run macros
Running a macro from the worksheet interface requires linking code to a visible control. Participants create their own button, assign a macro to it, and use form controls so routine actions can be started directly in Excel without opening the editor each time.
- assigning a macro to a button,
- using form controls.
10. Introduction to programming in VBA
At the programming level, the course establishes the building blocks used later in macro development and code editing. It explains procedures and functions, arithmetic, logical, comparison, and concatenation operators, as well as VBA data types for numbers, text, dates, Boolean values, and variants.
- procedures and functions,
- operators:
- arithmetic,
- logical,
- comparison,
- concatenation,
- VBA data types (variables and constants):
- numeric,
- text,
- logical,
- date and time,
- general.
11. Transforming texts
Text operations in VBA help automate work with labels, codes, and imported content stored in cells. The section covers concatenating strings, extracting specific fragments, changing letter case, and nesting functions to build more precise text transformations in formulas and procedures.
- concatenating character strings,
- functions retrieving a specific fragment of text,
- functions changing the case of characters,
- nesting functions.
12. Basic information regarding conditional statements and loops
Controlling program flow is essential when a macro must react to changing data or repeat an action many times. Participants work with If...Then...Else, Select Case, and the For, For Each, and Do loops, including step-by-step execution and early exit from a loop.
- step-by-step execution,
- conditional statement If ... Then ... Else If ... Else ... End If,
- selection statement Select Case,
- loop For ... Next,
- loop For Each ... In ... Next,
- loop Do ... Loop,
- early termination of the loop with the command Exit.
13. VBA and the Excel workbook
VBA works through the Excel object model, so this part explains how worksheets, cells, ranges, rows, and columns are addressed in code. It also covers classes, collections, object hierarchy, operations on the active cell, and creating or referring to worksheets correctly.
- objects in spreadsheets,
- classes and collections,
- object hierarchy in MS Excel,
- references to cells, cell ranges, columns and rows,
- operations on the entries of the active cell,
- references to worksheets and creating worksheets.
14. Applying the acquired knowledge in practice (example activities that may be performed during exercises)
Practical Excel tasks are used to connect VBA basics with everyday worksheet work. Exercises focus on automating data filtering, conditional formatting, grouping, table coloring for key areas, and file import, so participants can translate code into repeatable operations on real data.
- data filtering,
- conditional formatting,
- data grouping,
- table coloring (header, footer, even and odd rows),
- file importing.