ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   What is the purpose of a macro? (https://www.excelbanter.com/excel-discussion-misc-queries/167398-what-purpose-macro.html)

LINDA

What is the purpose of a macro?
 
I need to know more about macros--what is their purpose? What is a situation
where I would use a macro?

ExcelBanter AI

Answer: What is the purpose of a macro?
 
A macro is a set of instructions that can be programmed into Microsoft Excel to automate repetitive tasks. The purpose of a macro is to save time and increase efficiency by automating tasks that would otherwise need to be performed manually.

For example, if you have a large data set and need to perform the same calculations or formatting on each row or column, you can create a macro to automate the process. This can save you a significant amount of time and reduce the risk of errors that can occur when performing repetitive tasks manually.

Another situation where you might use a macro is when you need to perform a complex series of steps that are difficult to remember or execute manually. For example, if you need to import data from multiple sources, perform calculations, and generate a report, you can create a macro to automate the entire process.

To create a macro in Excel, you can use the built-in Macro Recorder tool. This tool records your actions as you perform them and generates VBA code that can be saved and reused later. You can also create macros manually by writing VBA code directly in the Visual Basic Editor.

Overall, macros are a powerful tool that can help you save time and increase productivity in Excel. By automating repetitive tasks and complex processes, you can focus on more important tasks and make better use of your time.
  1. Create a macro to automate repetitive tasks
  2. Create a macro to automate complex processes
  3. Use the Macro Recorder tool to generate VBA code
  4. Manually create macros by writing VBA code in the Visual Basic Editor

FSt1

What is the purpose of a macro?
 
hi
what is a macro. from the book....user defined add on programming.
It's a way to automate routine tasks that may be boring, tedious or time
consuming.
anything that you do with the mouse or keyboard can be duplicated with vb
code. in fact, anything that you do with the mouse or keyboard caused vb code
to run. a macro would reduce all the points and clicks and types to vb code
and do it a whole lot faster than you can.
each user is unique and has unique requirements so i cann't say how you
would use then. but i have use them to do a lot of things
one macro i have open 11 other files, downloaded data and update all the
files with current data, created a summary report and did it all a 5 AM while
i as still home in bed. my reports were on the printer when i got to work.
if you want to learn more about macros, see these sites....
http://www.mvps.org/dmcritchie/excel/getstarted.htm
http://www.the-excel-advisor.com/exc...-tutorial.html
http://www.exceltip.com/excel_links.html
http://msdn.microsoft.com/office/und.../odc_super.asp

the last one wrapped.
there are more.

good luck
FSt1
"Linda" wrote:

I need to know more about macros--what is their purpose? What is a situation
where I would use a macro?


David McRitchie

What is the purpose of a macro?
 
Hi Linda,
Kind of wished I'd answered first so that the answers get better
latter on, anyway here was my attempt, not a real definition.

Macros are generally code that is embedded into other code,
but with interactive usage such as in Excel this has changed a bit.

In Excel they are programming code to do some task(s) for you,
you can record a VBA macro yourself that will do the same as what
you did before (watch a video...)
http://www.datapigtechnologies.com/f...ordmacros.html
from http://www.datapigtechnologies.com/ExcelMain.htm
Basically if you do record a macro it will not be exactly what you
but will help you see what instructions you might need.

A macro is coding to help you do various things
1) include some functionality that Microsoft did not include in Excel
2) do the same thing as you've done before, but without having to
think about, or take a long time with tedious repeated tasks
(you might start by recording a macro)
3) use someone else code to modify or help with Excel

You can invoke a macro, or you can have an event driven macro that
starts when you do something.

--
HTH,
David McRitchie, Microsoft MVP -- Excel
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm


"Linda" wrote in message ...
I need to know more about macros--what is their purpose? What is a situation
where I would use a macro?



All times are GMT +1. The time now is 08:15 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com