How to write your first macro in VBA in Excel 2007
How to write your first macro in VBA in Excel 2007: Macros are written in a programming language called Visual Basic for Applications (VBA) which resembles VB in many ways. VBA has its own grammar or 'syntax'. The writing of the macros must follow this 'syntax' or grammar otherwise the macro will not perform as intended. In fact, you will get an error message. Unless you rectify your macro to meet the 100% requirements of VBA, the code will not execute as desired. For example, if you wish to display a simple message like 'Welcome to the world of macros' the program code has to be written exactly as shown in the training video. You start by typing sub followed by the name of the macro with brackets. The Visual Basic Editor automatically adds the code line 'end sub' on the next line. Between the 2 lines of code you write the code for the message. Inspite of the requirement of 100% syntax accuracy, VBA is easy to learn and implement with some practice.