Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Excel Programming with VBA Starter

You're reading from   Excel Programming with VBA Starter Get started with programming in Excel using Visual Basic for Applications (VBA) with this book and ebook.

Arrow left icon
Product type Paperback
Published in Oct 2012
Publisher Packt
ISBN-13 9781849688444
Length 62 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Robert F Martin Robert F Martin
Author Profile Icon Robert F Martin
Robert F Martin
Arrow right icon
View More author details
Toc

Table of Contents (8) Chapters Close

Excel Programming with VBA Starter
Credits
www.PacktPub.com
www.PacktLib.PacktPub.com
About the author
About the reviewers
1. Excel Programming with VBA Starter Index

Recording a macro, adding modules, browsing objects, and variables


Before you get your hands "dirty" with coding in VBA, there are a few things you need to know. These things will help when it comes to coding. In this section, you will learn how to:

  • Record a macro

  • Add modules

  • Browse objects

  • Get some background on declaring variables

We will start with macro recording, a feature which is available in most Office applications.

Recording a macro

A macro, in Office applications, is a synonym for VBA code. In Excel, we can record almost any action we perform (such as mouse clicks and typing), which in turn is registered as VBA code. This can come in handy when we need to discover properties and methods related to an object. Let us now have a look at some ways you can record a macro in Excel. There are two options:

  1. Recording a macro from the status bar.

  2. Recording from the Developer tab.

Option 1 – Recording a macro from the status bar

From the status bar, click on the Record Macro button. If the button is...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Modal Close icon
Modal Close icon