Questions?

Feel free to Ask a Question at the bottom of this page. I will respond as soon as I can. You are welcome to post anything related to programming, site improvement, or anything else.

VBA Word 2010

On this page you will learn about some of the basics of VBA (Visual Basic Applications) development. VBA was a spin off of Microsoft's Visual Basic 6.0. It was embedded into Word and quickly became popular for it's ease of use.

What can you do with VBA?

It can replicate nearly everything Visual Basic 6.0 could do to an extent. You can create forms complete with drop down boxes (combo boxes), textboxes, checkboxes, labels, radio buttons, sliders, treeview, etc. You can create tabs within your form. You can add scroll bars to your form. You can open multiple forms.

Colors

You can also change the color of the forms, you can change the color of the text, and you can highlight text as well. If you want to obtain a higher palette VBA has a built in command called RGB that accesses a standard color palette (such as used by Microsoft Paint).

Databases

VBA also has the ability to create databases and use SQL queries within. For my project I used an Access Database that retrieved keywords based on a query search. In a small way the project below emulates a simple google search. It searches Access for keywords in text fields to match a special text entry. This was created so I could more easily search a work database that often took time to find the proper listing.

Web Browser

VBA can also emulate a web browser with the WebBrowser control. This can be added by going to the Tools menu within VBA and selecting References. The web browser has some bugs in it. For example you cannot embed it within a tab or VBA will be unable to locate it. I eventually had to settle for keeping it on the top form.

Microsoft Tools

You can also execute Shell commands to call up the Windows tools such as the Calculator, Notepad, Explorer, etc.

The sky is the limit

I realized as I kept learning VBA that I was able to explore new words, such as having the ability to communicate directly with Excel, Access, Powerpoint and even Outlook. So learning this tool will aid you with some very powerful tools to help you stand out among your competitors.

FastNote (Project)

Below is a screenshot of a project I developed in my current role. This project enables me to quickly search an Access database to retrieve listings from matched linked entries. It also allows me to quickly notate an account, use a web browser to search the Internet, and access some Windows tools at the click of a button.

c# loops

Below is a YouTube channel I created that goes over some basic functionality of VBA. I'm hoping to exand this series once I finish other parts of this website.

VBA Videos (Below)

***
Subscribe to the Programmermind newsletter
Privacy Notice: Programmer Mind will not compromise your privacy