Experiment No.:13: Aim: Theory
Experiment No.:13: Aim: Theory
Experiment No.:13
Aim: Create an open office writer document and implement macro function.
Theory: A macro is a saved sequence of commands or keystrokes that are stored for later use. An example of a
simple macro is one that “types” your address. The LibreOffice macro language is very flexible, allowing
automation of both simple and complex tasks. Macros are very useful when you have to repeat the same task in
the same way over and over again.The usual methods for a beginner are to use macros that someone else has
written or use the built-in macro recorder, which records keystrokes and saves them for use.
Recording a macro
Make sure macro recording is enabled by going to Tools > Options > LibreOffice > Advanced on the main
menu bar and selecting the option Enable macro recording. By default, this feature is turned off when
LibreOffice was installed on your computer.
Step1: Open LibreOffice Writer and go to Tools, then Macros and select Record Macro.
Step2: Type the desired information. As an example, type any sentence.
Step3: Click on Stop Recording button on the small window and select the Module you want the Macro to be
saved in and click on Save.
Running a Macro
Step4: To run a recorded Macro, go to Tools, then Macros and click on Run Macro to open Macro Selector
Dialog.