Macros are automation tools that have been used for long. You could say that they have been used for process automation. Especially, if you remember VBA (Visual Basic for Applications) and have been a power user of Microsoft Office software, you have sure used macros for some of the other tasks. Macros are restricted not only to Microsoft Office applications but can be used to automate many other system tasks. In fact, today there are a host of macro recorders that could help you automate tasks and you need not have to struggle with codes and scripts or have knowledge of VBA and similar to code your tasks. Macros are all about automating a repetitive task, and macro recorders help you do just that. To give you a simple example, imagine you have dates in multiple formats in your spreadsheet. You would obviously like them to be in a uniform format before you prepare your report. Your macro can do that for you. Choose a convenient macro recorder, record your steps once, save it and replay it any time you require to use it again. There are a few things you need to keep in mind to achieve efficiency with how you record your macros.
How a macro works
A macro recorder usually records all the steps that you perform to achieve a task. These tasks can be anything from simple typing steps to running a series of commands, applying formatting, running a series of menu commands, exporting or importing data and even complex database operations. Once you have run the steps sequentially, your macro recorder simply remembers the steps. The next time you run it, it simply executes the same steps saving you precious time and the hassle of manually doing the steps again.
Basic precautions
Since a macro doesn’t have the ability to think on its own, it is important to teach the macro the exact steps that should be run. Therefore, you need to capture every move carefully in the same sequence that it should be executed. A mistake in one of your steps, for example, a button that should not be clicked, and your macro recorder will remember that too. This would obviously record a wrong macro sequence and would thus be worthless, making you re-record the steps again. Thus, it is a good practice to have the exact workflow in mind or written somewhere, so that while recording, you run the steps in exact sequence. But, in case, you do commit a mistake, do re-record the process, so that your recording is smooth, and the macro runs efficiently when you play it back.
Keyboard macros are the best
Always prefer to record your macros using a keyboard. They are any day more reliable. Since the keyboard is agnostic of your windows positions or screen coordinates, or resolutions, unlike something recorded using a mouse, the execution of the macros happens exactly as required. A mouse recorder, on the other hand, records every relative coordinate and therefore often fails when the system and the screen environment changes. Always use common keyboard commands such as Alt – to get to the menu, to close a window, use Alt+F4, or the Esc button to close a dialog box, and use arrow keys for navigation purposes. Never record any mouse moves unless there is a very specific need. Many macro recorders give you specific options to disable mouse moves. It is always a good practice to disable recording of mouse moves.
Other efficient techniques
Do not use delay commands. By using such commands, you would tend to make your macros inefficient as they take more time to execute. Therefore, speed-up operations by decreasing use of delay commands. If need be, specifically select any parts that use the delay feature and edit them not to use any delays, thus increasing the speed of execution. Also, when recording, always start and end at a known location. Use the initial keyboard strokes to move to the desired location before you start recording a macro. As an example, you could use the HOME keystroke to move to the beginning of a line. The same principle applies when you want to end your macro. Always think through iteratively, and you are on your way to recording efficient macros.