How to create macro in Excel complete tutorail

Hey, guys here is another useful tutorial. Today we will learn about How to create macro in Excel in 2003,2007,2011 and 2013, use of Macros.  As you know by creating Excel macros you can save time and headaches by automating common, repetitive tasks. Excel macro is like a programming that runs in Excel and helps us minimize the time that is used for repeating the task.

How to create macro in Excel

we will cover the following topic in this article

1. what is macro and macro definition
2. what is VBA
3. How to create the macro in Excel

 Macros Definition

  1. A macro is a recording of your action that you applied in Excel sheet.
  2. later you can use your recording to other excel sheet and reduce your time and get a result.
  3. for example, if you are going to find a sum of a column, you can record the action and next time in another excel sheet you can apply macro and find an accurate result.

you may also like… python is not recognized as an internal or external command | how to install python

What is VBA in Excel

VBA stands for Visual Basic for Applications, IT  is a powerful programming language tools that allows you to write your own functions or commands in an Excel spreadsheet that works like a programming language. These code written in VBA can help you to design an button or textbox etc and that works on a button click. in another word, you can say that by using VBA you can use your programming logic to in Excel.

How to create macro in Excel?

you have to follow the following step of creating macros in Excel

step 1: first, you have to enable the developer option

for MS Excel 2010, 2013, 2016

  1. click the File tab.
  2. then click on options.
  3. click on Customize Ribbon.
  4. Under Customize the Ribbon and under Main Tabs, select the Developer check box.

for MS Excel 2007Click on the Microsoft Office Button

  1. then click Excel Options.
  2. powerPoint Options
  3. Click Popular, and then select the Show Developer tab in the Ribbon check box.
how to create macro in Excel
Enable developer mode
step 2: Import a CSV file or create an excel file

in this article, I will create an excel file and assign a macro to it.

Excel Macros example
Excel Macros example
step 3: click on developer Tab and you will get VBA and Macro option
VBA and Macros In excel
VBA and Macros In excel

ASSIGN a Macros

you may also like….  C program to find the length of a string

step 1: click on record Macro one window will be open fill value as your choice
fill macros value
fill macros value

step 2: Macros is started and whatever you will do that will be saved in the macro

assign a macros
assign a macros

 

your macro is created now you can Implement macros in another project and reduce your time and calculation.

Import Macros in another Excel File

step 1: Create an Excel File

Implement Macros
Implement Macros

step 2: click on developer tab then Macro, one popup window will be open

Import macros in Excel file
Import macros in Excel file

 

select your macro and click on Run button, now you are done.

the value will be automatically filled

Macros example
Macros example

 

final word:- 

if you have any doubt or problem regarding  Macros in Excel. Then you can feel free to ask the question. So, write your problem in the comment box. Because we are here to solve your all doubt.

 

Leave a Reply

Your email address will not be published. Required fields are marked *