Free Microsoft Excel Training Videos

Writing Macro - VBA Editor

Another example about writing macro in VBA editor to calculate the total of salary and perks.
To write a macro in Microsoft Excel you need a knowledge of the programming language Visual Basic for Applications(VBA). VBA is easy to learn and gives you a powerful tool to automate your work in Microsoft Excel. Also you can create new applications in Microsoft Excel if you can write macros. Practice will make you perfect.
  • Click on Tools in the menu bar.
  • Select Macro.
  • Select Visual Basic Editor.
  • In the Visual Basic editor window, select 'Insert' from menu bar.
  • Select Module.
  • Start writing your code as demonstrated. This macro calculates the 'Perks' and the 'total'
  • After completion, click on the run button in the 'tools' bar as shown in the Excel training video.
Further reading on VBA
Excel VBA

Writing macro - vba editor