VBA101: A practical guide for VBA user
June 6, 2011 1 Comment
I wrote this guide a few months ago (September, 2010) and I think it might be something useful for people, who are interested in VBA (Visual Basic for Applications).
Things to know
- VBA stands for Visual Basic for Applications
- VBA only works with Microsoft Office for Windows
- VBA allows user to programmatically use Microsoft Office
- Press Alt+F11 to jump to Visual Basic Editor view
VBA can …
- Automatically update the document
- Connect to database and populate information
- Do Forms
How to write a Hello World in VBA
Sub MyHelloWorld()
MsgBox “Hello World”
End Sub
Note about VBA
- Comment is ‘
- No ; at the end of the line
- No {} for block code
- Use Dim to declare variable
- Assigning values to Primitive types do not require Set
Advertisement
The nice thing about visual basic for applications and what makes it a skill set worth having is Microsoft office is the main program suite issued with almost every PC in the work force. Good job touching on this in “things to know”.