![]() |
|||
|
|
|
|
Discovering Macros History of Excel MacrosWhy the renewed interest in Visual Basic for Application (VBA) for ExcelThe capacity of the computer on your desk and its memory have grown 1,000-fold in the last 10 years and your personal computer is now part of a network within your company. This network even connects you to the world through the Web. This is why VBA for Excel is so popular among users of all ages and professional backgrounds. VBA is used to develop simple and useful programs (macros) or sophisticated and powerful programs (VBA procedures) within Excel. These applications can be stand-alone or back-ends and front-ends to central databases and accounting-, sales- and manufacturing-centralised programs. You can now do things with Excel and VBA that were impossible even 5 years ago. You can do things today that previously required you to consult with a computer specialist who often did not know anything about your professional needs. VBA is a programming language for users who want to make things happen by themselves. VBA is a programming language that can be mastered by anybody even without programming background. With VBA you can rapidly develop small macros to get rid of tedious and repetitive tasks. You can also develop large programs that will do exactly what you need at a fraction of the cost of commercial programs. In In contrast with these huge programs, your application will not require massive training and will not include tons of functions that you will never use. When you develop your own programs there is NO COMPROMISE. You get exactly what you need, and only what you need. No more, no less. With VBA the magic word is automation. Automate your reports and your analysis. Get results faster. VBA for Excel allows you to develop tools that you need at a cost substantially lower than any other programming language . Because you develop them yourself and because you are the principal actor in the development process, your output is EXACTLY what you need. You will master the technology instead of being enslaved by it. History of VBAIn earlier days, Excel users would call them MACROS (macro commands). They would assemble a series of keystrokes and Excel would remember the sequence and perform such routines any number of times. It saved time and money. Behind the scenes, these macros were automatically built using a programming language called VBA (Visual Basic for Application). You can still learn very easily how to develop such useful tools using the Excel Macro Recorder. But now you can also go behind the scenes yourself and develop very powerful programs within Excel using VBA, the easy-to-learn macro-programming language. Where does VBA (Visual Basic for Application) come from?In the 1970s, a new computer language for non-programmers appeared. Basic-- as it was called-- was conceived to be a very simplified version of English to communicate with a machine. With Basic, mastering less than 150 words would allow you to develop programs that would accomplish the most complex tasks. Some of you used Basic on advanced calculators (TI 59) and on Radio Shack's old COCO64. At the time, RAM (memory) and CPUs (the computer's brain) were very, very small and there were limits to what you could do with the language. With today's computers came Visual Basic (VB). It is still Basic but a lot of elements are pre-programmed making the user's task much simpler. Microsoft adopted the language and introduced it as a component for all its major application programs, including Excel, Access, Word, Project, and Power Point. Microsoft called these different versions Visual Basic for Application. What is the difference between VBA for Excel, VBA for Access, and other VBAs?To answer this question I will ask you to imagine a meeting of five English-speaking persons; a lawyer, an accountant, a physician, a chemist and a psychologist. They understand each other when they talk about the weather or about sports. But when it is time to talk about their work, none of them totally understands the other because they each have a special professional vocabulary. Only the accountant talks about debits and credits and only the physician uses the word tracheostomy. It is the same with VBAs. For example in Excel you work with worksheets and formulas but these entities do not exist in Word or Power Point. In contrast, general vocabulary in all VBAs includes Delete, ClearContents, Quit, Close, Loop and other generally recognizable terms. If you speak English you can easily learn any of the VBAs. VBA for ExcelVBA for Excel is the most user-friendly of the VBA languages because of its Macro Recorder. This simple and powerful tool will write sentences for you. The Macro Recorder not only teaches VBA to newbies, but remains the best teacher and a great assistant for the duration. You will find a special lesson on the Macro Recorder on this website (Lesson 7) and an even more complete one in the downloadable tutorial on VBA for Excel (Macros). The other very friendly part of VBA for Excel is its programming environment. You open the Visual Basic Editor in which you will write your macros and test them. The VBE is as easy to work with as your Email program. In the VBE you can test your VBA procedures (macros) step by step while seeing them at work directly in your spreadsheet on the same screen. While testing you can modify things, go back a few lines and proceed with the test. So not only is VBA easy to learn but its programming tools are also very user-friendly. History of Excel Macros |
|
|