VBA Notes
Lesson 3. About VBA Macros
A macros is a piece of programming code that runs in excel environment, and it helps to automate routine tasks. In other words, A macro is a recording of your regular steps in excel, which you can replay using a single button.
Importance of Macros in Excel
You can import the data into the format and excel. Every day you will be required to perform the same ritual. It might become boring and understanding.
Macros solve such problems by automating these routine tasks. So you can use a macro to record the steps of
Importing the data.
And you are formatting it to meet your business reporting requirements.
Macro Basics
Macros are one of the developer features. But the Tab for developers is not displayed in excel. So, you will need to present it via the customized report.
Macros are used to compromise your system by attackers. They are disabled in excel. If you want to run macros, then you will need to enable running macros and only run macros that you believe. It comes from a trusted source.
If you want to save the macros, then you must protect your workbook in a macro enabled format *.xlsm and the macro name should not contain any spaces.
How to Write Macros?
Let's see how to write a simple macro in a step by step manner such as:
Step 1: Go to the File and click on Options in Excel.
Step 2: Click on the Customize Ribbon Tab and select the Developer.
Step 3: Click on the OK button.
Step 4: Click on Developer Tab. Developer tab appears in the menu bar.
Step 5: Click on the Record Macro
Step 6: A dialog box will appear to you.
A. Enter the macro name
B. Create shortcut keys by press ctrl, if you want.
C. Type Description
D. Click on Ok.
Do work in excel
After finish your work in excel, then click on Stop Recording.
1. Go to another excel sheet.
2. Click on Macros.
3. Select Macro name.
4. Click on Run.
Happy Learning
Thanks for Visit This Post. Computer Related Any Query Please Contact Us.
Call / WhatsApp: +91 9650597419 (Vinay Sir)
Post a Comment
0 Comments