Hello, and welcome to the first article on Visual Basic. During the next few weeks, we will be exploring the wonderful world of Visual Basic, and give you the grand tour of all it’s major tourist sites. My name is Peter, and I will be your guide in this process.
Our first trip will take us to the past, it will explainwhy you would want to be here, and a peek at what weactually can do.
First of all, let’s look at a little history of Visual Basic. Visual Basic (VB) is a 4th generation programming language, which is targeted specifically for the Windows platform. VB was derived from BASIC (Beginners All-purpose Symbolic Instruction Code). The purpose of BASIC was to provide programmers a more or less English version of a programming language, with easy-to-remember syntaxes and keywords.
In the past (maybe you have seen some of this code), programmers had to go by line-numbers, and basically had to know in advance how their application would work. They just started whipping up code, and referred to line numbers all the time. This is very error-prone, and time consuming. With VB, there are no line numbers. Ourcode is structured into functions and routines that each do their little thing. Yes, they can call each other, and have loops, but instead of seeing ‘Goto 150’, you might do something like: ‘Call ConvertCelciusToFahrenheit’, which makes the code a lot easier to read.
Visual Basic is based on Object-Oriented programming. This might seem vague, but during the weeks, you will start understanding what this means. For now, let’s leave it at Object Oriented (OO) meaning that you can easily re-use your code in different programs.
VB is event-driven. This pretty much means that when we program, we distinguish events. I.e. A user clicking a button, selecting a menu option, etc. Event-driven means that the program itself won’t do anything, until the user does something.
Think of it as a car. A car will remain on your driveway forever, if you don’t do otherwise. If you insert your key into the keyhole and twist it, the door will unlock. If you start the car, the engine will start. All these actions can be seen as events. Basically, the car won’t do anything until you start it, shift it into a transmission, and slam the gas. A program is similar. It can perform small tasks meant to prepare the program for ‘the gas slamming’ (i.e. it could gather user-input to determine exactly what it is a user wants to do), or it can actually take you to the highway at 150 / hour ( i.e. move data from one database to another).
WHY you would be wanting to learn about Visual Basic?
Well, the question here is: Why wouldn’t you? If you’re working on the Windows platform, you have a few programming languages to pick from. There’s C++, Delphi, and VB. (I am aware there are others, but the three major ones would be these). Visual Basic was built by Microsoft itself, (They also do carry Visual C++) and is very easy to learn. I’d say the ease of use is one of the best reasons to pick VB.
What can you do with Visual Basic?
Let’s sum up a few possibilities of various ways to program using VB.
Desktop applications: These are your standard applications like notepad, calculator, etc. Applications meant for a few users at a time, running locally.
Distributed applications: These are applications meant to be used by massive amounts of users, often running on dedicated servers over a network. Think of a multi-user helpdesk application, or an order-entry program.
Web-based applications: Applications running in a browser. These are applications that make use of the Internet. Think of online databases that can be consulted by thousands of simultaneous users.
Database applications: Applications making use of databases (Like SQL Server, Oracle, etc)
DHTML: DHTML is Dynamic HTML. It’s basically a more flexible version of the Hypertext Markup Language, as used on the Internet.
ASP: Active Server Pages are another implementation using the Internet. ASP adds functionality, gives you the option of using components online, and can add security to your webpages.
ActiveX DLL / ActiveX EXE: ActiveX is where the component-based programming starts. These are reusable bits of code you can implement in many different programs.
That’s it for this article. Join us next time to take a look at different versions of Visual Basic, and the installation process itself.