Starting a Macro in Excel

    

613-749-4695 (Peter)
[email protected]

Home Page

Tips and Ideas on Excel
Table of Contents on Excel

Tips and Ideas on Macros
Table of Contents on VBA

Quick Links

 

VBA Chapter 9 of 24: Starting a Macro in Excel

When does the VBA procedure (macro) start? When an EVENT happens. The event is what triggers the VBA Excel procedure.

From the Menu Bar

In Excel you can run an Excel VBA macro  by going to the menu "Tool/Macro/Macros.." then select the  macro from the list and click "Run" .

VBA for Excel Macros Window

Open many workbooks with macros in them. When you go to the menu "Tool/Macro/Macros.."   you will notice that you have access to all the macros from all the open workbooks. This means that you can store ALL your useful Excel macros in a single workbook (call it myMacros.xls) and have access to them while the workbook is opened. Let's say for example that you have designed a macro that multiplies the content of a cell by 2. If "myMacros.xls" is open you can call this Excel macro  from any cell in any other workbook that is open. No need to copy your essential macros in all your workbooks just open myMacros.xls and put them to work.

Clicking on a Key of your Keyboard

First you need to program a key. To do so go to "Tool/Macro/Macros.." then select a  macro from the list. Click on "Options" and follow the instructions. A suggestion, assign your macros  to upper case keys ("Shift/A" instead of "Shift/a for example) to make sure that you don't use one of the many lower case keys that are already used by Excel. You can also assign a macro to a key when you use the Excel Macro recorder.

 

Next Chapter: VBA for Excel Code Tips

VBA Table of Contents
or use the quick links below

 

Discover Even More in 50 Excel spreadsheets

 

    

613-749-4695 (Peter)
[email protected]

Home Page

Tips and Ideas on Excel
Table of Contents on Excel

Tips and Ideas on Macros
Table of Contents on VBA

Quick Links

Starting a Macro in Excel