View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Blue Hornet Blue Hornet is offline
external usenet poster
 
Posts: 5
Default Learning VBA online for Excel


gandhi318 wrote:
I wish all the members a happy and prosperous new year

I am 54 years. Started working on computers since 1990 or so starting
with Word Star and Lotus. Switched over to MS Office from 1997
converting or using Lotus files from Excel. Now I am extensively using
Excel for all my office work Salaries, Income Tax, Provident Fund,
Monthly and Annual Accounting. I am better in using all the Menus and
take their benefits including use of functions. I am able to record
simple macros for the repetitive tasks, assign them to self-created
tool bar, menus, sub-menus (controls) and key board letters with Ctrl+
keys but cannot write macros myself as I do not have the knowledge of
VB. I want to learn more abouot VB and programming in Excel. Can I
learn on-line easy-way without academically learning through big books.
Please suggest easy way to learn VB and preparing macros which would
easy my office work and I can put all my work in a programme/software
style.

Thanks

Gandhi


--
gandhi318Posted from - http://www.officehelp.in



My age and experience closely parallels your own, except that I am so
lazy that I *had* to learn VBA in order to save steps later. I suppose
it's a toss-up whether the time I've spent learning VBA has actually
saved any time or steps in my processing but ... I do know some VBA
now.

The way I learned was to record simple macros, as you have done, and
then read them (Alt-F11) to see how they worked. (I had the added
benefit of having worked with simple Lotus 1-2-3 keyboard macros, so I
knew some of the things that I wanted to do in Excel.) My first step
was to find out how to make things interactive.

As you know, the macros you record are explicitly literal, having
worksheets named exactly what they were when recorded, operating on
exactly the same ranges, etc. So I wanted them to operate over
different workbooks, different sheets (or all sheets) and different
ranges.

Then I had to learn the various Looping constructs For ... Next; Do
While; Do (until), etc. Conditional programming with If / Then /
ElseIf / End If ... and you'll be off and running before you know it.

More often than not I will still "record" a macro to do a bit of
complex processing, and then use VBA to fine tune it (the code is
pretty boggy "as recorded"), add looping, conditions, user inputs,
error traps, etc. And comments. Don't forget to add comments!