The first step is to open up the workbook (file) that you wish to use the macro in.
* click on Tools,
* Macros
* And then select Record new macro from the menu.
You will see :
Name - Type the name of your macro.
Shortcut key - (optional) this has to be a letter, we have used h, so in our example the macro will run every time we hold down the CTRL key and press the H key.
Store macro in - This would normally be the workbook you are working on (this workbook), but you can save macros into a personal macro workbook.
Description - Here you can enter a description of the macro for your benefit.
When you have finished filling in the information click the OK button to start the macro recorder.
Everything you do now in the workbook will be recorded, so manually go through the process that you want your macro to recreate, for instance adding up a column.
When you have finished click on the small blue square within the macro recording box to stop recording.
Playing the macro back
To run the macro click on
* tools,
* Macro,
* Then select Macros.
your macro should be in there ready to use.
select it and then click the Run button.
The macro dialogue box also allows you to delete and edit macros, for instance by clicking on the Options button you can assign or change the keyboard shortcut associated with each macro.
If you have assigned a keyboard shortcut to a macro then you can run it by holding down the CTRL key and pressing the associated letter.