# best book to learn VBA



## Tom F (Jun 16, 2007)

What book have you found to be the best to learn VBA and why?

Thanks,
Tom


----------



## mikerickson (Jun 16, 2007)

I like Walkenbach's Power Programming with VBA.


----------



## Richard Schollar (Jun 16, 2007)

I second Mike's recommendation, but would also highly recommend Excel 2002 VBA Programmer's Reference by Bullen, Bovery, Green and Rosenberg (if you have xl2007 they have a version specifically targeted at this version too).


----------



## mordrid (Jun 16, 2007)

Another one that I like is VBA and Macros for MS Excel by Bill Jelen (Mr Excel) and Syrstad


----------



## Hermanito (Jun 16, 2007)

My two favorites (and at the same time the only books about VBA that I have   ) are:
- Programming Excel with VBA and .NET (Steve Saunders & Jeff Webb, O'Reilly)
- Professional Excel Development (Stephen Bullen & Rob Bovey & John Green, Addison Wesley)

I'm planning to buy some more sometime, so I'm watching this thread for good ideas...


----------



## VoG (Jun 16, 2007)

I have the 2007 version of Richard's recommendation - yes it is good but I would imagine very hard going for a novice.

Take a look at this http://www.add-ins.com/vbhelp.htm which is excellent if you wish to learn by example. You can copy and paste then modify the examples. It doesn't cover everything but in my opinion is great to get you started. I still refer to it from time to time.


----------



## dcardno (Jun 16, 2007)

I will pile on...

John Walkenbach's "Power Programming with..." (pick your version) are excellent for anyone starting from a VBA novice up to the expert or near-expert level.  There is enough introductory material on using Excel without VBA (three chapters out of 30 in the XL2K version, 4/31 in the XL07 edition that I have picked up but not yet gone through) that he can proceed on the assumption that everyone is at a reasonably competent Excel user level.  From there, the book goes up to a very advanced level, including controlling other applications from Excel, developing complete applications, etc.

Bullen / Bovey / Green / Rosenberg (for 2K) and Green / Bullen / Bovey / Alexander (Excel 2002 VBA Programmer's Reference and Excel 2007 VBA Programmer's Reference, respectively - note the caveats on most of the author's websites regarding the Excel 2003 version by Paul Kimmel) are both very good, but are aimed at a slightly higher level; I don't think they are as good as the Walkenbach books unless you have done a fair amount of work in VBA or another programming language.  In a nutshell, Walkenbach's books are terrific for someone who intends to develop sophisticated files for their own use, or for a small work group, and is starting without a huge amount of programming or VBA background.  The Bullen _et al_ books seem to target someone who might be developing either for a larger audience, or for more of an 'industrial strength' application that might involve Excel as a front end for a corporate database or gather information from various sources, but don't provide as much introduction or basic material (and moves pretty quickly through what of that stuff is provided).  I should point out that while I think Walkenbach is a better learning resource, 'Bullen' is the book that sits beside my monitor at work as a reference: it just isn't as approachable - I was glad I had already read Walkenbach (and done quite a bit of work in VBA based on what I learned from it) before I started on 'Bullen.'

"Professional Excel Development" was mentioned above - this is an absolute case of truth in advertising, and the title describes the target market: capable VBA developers who are trying to put together bullet-proof applications for wide deployment (wide enough that direct support is not an attractive option) or possibly for professional sale.  The authors (Bullen, Bovey, and Green, who co-wrote the two 'Bullen' books) assume that you know a great deal about Excel and VBA - and if you don't you will be swamped.  This is most definitely *not* a book to use to learn VBA: my guess is that the target market consists of people who are in the top decile of participants on this board in terms of Excel knowledge (ie - the ones who answer _a lot_ more questions than they ask) and the top one or two percentiles of Excel users in general.

Other Excel / VBA Books:
Excel 2K VBA Fundamentals - Reed Jacobson: Very basic, and not worth much IMHO.  The examples are contrived and trivial, and it takes _forever_ (or at least, several pages) of step-by-step screen shots to describe the simplest task.  I was not some kind of super-VBA expert when I read it, but I gave up on it almost immediately: the Walkenbach book(s) start at the same "intermediate" level, but progress much faster, go further, and provide broader and deeper knowledge

Definitive Guide to Excel VBA - Michael Kofler.  Comprehensive, but slightly strange language (translated from German - sometimes you can see it in the sentence structure) and poor screen shots get in the way a bit.  As well, the terminology used to describe arrays is non-standard, which may be a translation quirk as well.  The book is comprehensive, but while I refer to Walkenbach occasionally and 'Bullen' sits by my monitor, this one sits on my bookshelf - perhaps I passed the point of diminishing returns on Excel reference books at the point where this one arrived from Amazon.

VBA for Modelers - S Christian Albright: a candy mint _and_ a breath mint!  The first half of the book is simply about VBA on a stand-alone basis, and it moves at a very fast pace (the book is intended as an MBA-level text for finance and Management Science / Operations Research students, so Albright assumes that the reader is pretty clever).  The material is well presented, but it is very directed and there is no hand-holding.  The second half applies Excel as a programmable tool to deal with problems in those areas: product mix; portfolio optimization; option pricing; production scheduling, etc.  If you have no interest in those areas, then the VBA portion alone probably isn't enough to sell the book; if you do, then it is a really good one to have in the library, with the VBA portion (which _is_ pretty good) as a bonus.


----------



## Tom F (Jun 16, 2007)

Thank you for your recommendations.

I have no experience with this, therefore am looking for a book to ease into it from a beginner's level.

What is the difference between VB and VBA for Excel purposes? Which would be better to learn?

Thanks, 
Tom


----------



## Smitty (Jun 16, 2007)

> What is the difference between VB and VBA for Excel purposes? Which would be better to learn?



VB is a stand-alone application used to create stand-alone applications. VBA stands for Visual Basic for Applications and is the underlying programming language for most pre-2007 Office programs.

VBA is based on VB, but more program specific (i.e. VBA for Excel and Access uses different procedures).

If you're interested primarily with working in Excel then VBA is the way to go; if you're interested in building stand-alone applications then VB is the way to go.

HTH,

Smitty


----------



## Richard Schollar (Jun 17, 2007)

> I have no experience with this, therefore am looking for a book to ease into it from a beginner's level.



Tom, if you're completely new to programming, then another of John Walkenbach's books is utterly superb (in an earlier incarnation it was the one I learned with):

Excel VBA Programming For Dummies


----------



## Tom F (Jun 16, 2007)

What book have you found to be the best to learn VBA and why?

Thanks,
Tom


----------



## mikerickson (Jun 17, 2007)

"Excel VBA Programming for Dummies" is a different book than "VBA for Dummies". 
I haven't read "Excel VBA Programming for Dummies" that Richard recommended, but I don't think much of "VBA for Dummies."


----------



## Tom F (Jun 17, 2007)

mickericson,

I've had an exposure to BASIC programming years back. The "dummy" book route sounds like a good starting point.

Thanks for all the posts. This board is awesome!

Tom


----------



## SydneyGeek (Jun 17, 2007)

> I don't think much of "VBA for Dummies."



I bought this a while ago, and I agree. It's pretty good as a structural book on VBA, but if you want to use it for Excel, there's much better material about. However, it's not bad if you are trying to work out how to program in Visio (which is where many of the samples are targeted). 

Denis


----------



## Tom F (Jun 20, 2007)

Just wondering ... is the 2007 Excel version compatible to the 2003 Excel version as far as VBA code or will they be different?

Thanks,
Tom


----------



## Richard Schollar (Jun 21, 2007)

There are differences (Application.FileSearch has been removed in 2007 for example, among others).  Many of the differences will likely relate to the different ways of doing things eg Pivot Tables and file formats in 2007 compared to 2003.  The structure of the VBA language is pretty much unchanged though.


----------

