Page 167 - IT_V1.0_Class10
P. 167
Organising a Macro
When we create a macro in Calc, we’re making a set of instructions that computer will follow to perform tasks
automatically. To make sure macro works well and is easy to manage, keep it organised.
When organising a macro in Calc, focus on these key points:
Break it Down: Divide your macro into smaller, manageable sections.
Use Clear Names: Name variables and parts of the macro clearly for easy understanding.
Add Comments: Include notes in your code to explain what each part does.
Handle Errors: Make sure your macro can deal with problems without crashing.
Test Regularly: Check your macro to ensure it works as expected.
The steps to organise a macro are as follows:
Step 1: Create a New Spreadsheet.
Step 2: Click on the Tools menu from the Menu bar. Then, select the Macros option. A sub-menu appears
on the screen.
Step 3: Click on the Organize Macros and then click on the Basic option. Alternatively, you can use the
Alt + F11 shortcut key to quickly open the Basic Macros dialog box.
2
3
The BASIC Macros dialog box appears on the screen.
The Macro From section contains available macro library containers.
My Macros contains macros that user can write or add to LibreOffice.
Application Macros contains macros included with LibreOffice and should not be changed.
Step 4: Click on the Organizer button.
The Basic Macro Organizer dialog box appears on the screen.
Using Macros in Spreadsheet 165

