Excel VBA Introducing The Visual Basic Editor, And Recording Our First Macro

preview_player
Показать описание

In this lecture we will take a look at the Visual Basic Editor (VBE)...this is the environment where you will write, and modify your VBA code.

I'll show you how add the developer ribbon, if it's not already visible, which is one of the ways to access the VBE. The other, and by far the quickest, is to use the keyboard shortcut ALT + F11.

We will go through how to record our first macro (a macro is just a recorded sequence of keystrokes) in 3 different ways.

1. From the Developer ribbon (record a macro)
2. From the View ribbon (record a macro)
3. Click the "record" button to the bottom left of the screen.

We will talk about the naming conventions for what to call your macros...(hint: call them something descriptive!).

Once we've recorded a simple macro, we will go "under the hood", and back into the VBE and take a look at the VBA code we just created!

All macros begin with the word "Sub" and always end with the words "End Sub".

In the VBA programming language, some words are reserved...that is, they have special meaning and do specific things. You can spot these words easily, because they always auto-capitalise and they are also in a blue typeface.

You will also see some of the writing in a green typeface...these are REMarks...remember the 15 Golden Rules of Coding? The are just notes we can add for our own convenience.

Finally, we have writing in black typeface...this is the "Executable" code...this is the stuff that actually does the good stuff!

Finally, we will take a look at a few ways to execute, or "run" your code.

This is a sample lecture from my course, Microsoft Excel Essentials: Level 3 - VBA Programming. This course is for Excel 2007, Excel 2010, Excel 2013 and Excel 2016, 2019 and 365

Get this course now!

Level 1: Microsoft Excel Essentials: Level 1 Basics - Excel Made Easy
The complete 4 hour course is yours for a low cost monthly subscription (first 2 months free!):

Level 2: Microsoft Excel Essentials: Level 2 - Intermediate/Advanced
The complete 9 hour course is yours for a low cost monthly subscription (first 2 months free!):

Level 3: Microsoft Excel Essentials: Level 3 - VBA Programming + Macros

Alternatively, you can purchase the complete set in...
Excel Essentials: The Complete Excel Series - Level 1, 2 & 3

The WHOLE 27.5 Hour Excel Mastery Series In One! From Excel Novice To VBA Programmer...
Available to buy with lifetime access for just $16.99 (normally $200) here:

This course is for suitable Excel 2007, Excel 2010, Excel 2013, 2016, 2019 & 365

Videos in the Level 1 series:

Videos in the Level 2 series:

Videos in the Level 3 series:
Рекомендации по теме
Комментарии
Автор

this course is so useful, thank you very much sir. im gonna share this to my friends

MikelRasyid
Автор

Alan, you have a great knowledge of excel man. I loved all your videos... it helped me a lot. I have started with zero knowledge and now at least I can do something with excel.

thanks

ashish_Jha
welcome to shbcf.ru