Visual Basic 2008 Programming: Business Applications with a Design Perspective
Chapter 1 Chapter 2 Chapter 3 Chapter 4 Chapter 5 Chapter 6 Chapter 7 Chapter 8 Chapter 9
Chapter 10 Chapter 11 Chapter 12 Chapter 13 Chapter 14 Appendix A Appendix B Appendix C Home
Last change: February 13 2016 18:48:19.

Table of Contents

 Chapter in PDF

Chapter 1: Introduction
Last change: February 13 2016 18:48:20.

Evolution of Visual Basic

Visual Basic evolves from BASIC, an acronym for Beginner’s All-Purpose Symbolic Instruction Code, which was created in the 1960s. Its syntax is similar to FORTRAN, another programming language that was developed to handle Formula Translation. However, BASIC was used primarily for interactive computing, while FORTRAN was used in the batch-processing environment where each program was run as a job without human interaction or intervention. When microcomputers were introduced, BASIC was the language available in nearly all makes, such as Tandy, Apple, and so on. Its power was fairly limited because of hardware limitations. When the personal computer (PC) became available, Microsoft introduced GW-Basic with its disk operating system (DOS).
As you may be aware, programs written in BASIC (any version) need to be processed by a language processor (a program that processes the BASIC program) before their instructions can be understood and executed by the computer. The BASIC language processors up to that point were interpreters that read one line of BASIC code at a time, interpreted the code, and carried out the activities called for by the instructions. Because of the overhead associated with interpreting the code, the execution was very slow.
To improve execution speed, BASIC compilers were introduced. A version of the BASIC compilers by Microsoft is Quick Basic. A compiler is another kind of language processor that translates a source program, such as a program written in Quick Basic, into the machine language or some pseudo-code that is fairly close to the machine language. The resulting program is recognized as the object program, orexecutable, in modern terminology. Because of the elimination of the overhead of interpretation, the object program runs much faster than a source program under an interpreter.As you can see from the diagram in Figure 1.1, the key difference between an interpreter and a compiler is the output. The interpreter takes the source program along with the data as input and produces the results that the source program calls for. Under this arrangement, each time you need to run the source program, you will need to invoke the interpreter. In contrast, the compiler takes only the source program as input and produces an object program in a lower-level language. The object program must be run along with required data to produce the results. Note that the object program can be run many times with different input, and without being compiled again as long as the source program is not changed.

Figure 1.1
Difference between Interpreter and Compiler

Difference between Interpreter and Compiler: The former produces results of computations; the latter produces an object program, which needs to be loaded into the memory to run in order to obtain results.

Despite its speed, Quick Basic has its drawbacks, especially by today’s standards:
It is a procedure-oriented language. When it runs, the program, instead of the user, dictates the sequence of activities to be carried out. The user is not allowed any flexibility.
Its interface is text based instead of graphics based. The appearance is not attractive. The keyboard is used nearly exclusively to obtain user input or commands. In many cases, text-based input is more susceptible to errors and may not be as efficient as other gadgets that are available in the graphics-based environment, such as check boxes, radio buttons and combo boxes.
Programs take a long time to develop and are difficult to change, especially when the change involves the visual interface. The programmer needs to track all the details relating to the location, size, and color of all boxes and texts drawn on screen. A minor change can call for painstaking efforts by the programmer to ensure that everything is done correctly.

After the graphic user interface (GUI)-based Windows operating system was introduced for PCs, Visual Basic (VB) arrived in 1991. The first version of VB had two editions: one for the DOS, and another for the Windows system. As the Windows system gained in popularity, the later versions of VB were designed only for the Windows operating systems. Earlier versions of VB were written for 16-bit operating systems because 32-bit operating systems were not yet available. There were two editions of VB in version 4: one for 16-bit operating systems, such as Windows 3.0)  and another for 32-bit operating systems, such as Windows NT and Windows 95. Since version 5, all editions have been made exclusively for 32-bit operating systems. Version 6 expanded several language features and supported ActiveX Data Objects (ADO) for data access. VB.NET was introduced in 2001 as a result of a sweeping overhaul to the language and offers the object-oriented features of modern programming languages. VB.NET 2005 simplified the coding requirements for forms and controls. The current version, VB.NET 2008 provides convenient intelisense hints to the developer while writing code, making the code writing process much easier and more efficient. The following table briefly highlights the milestones of the evolution of VB.

Year Milestone Remark
1964 BASIC For interactive computing in mainframe computers
1970’s BASIC In various microcomputers/PC (BASIC and GW-Basic)
1985 BASIC and Quick Basic Processed by compilers
1991 Visual Basic For Windows or for DOS
1992 Visual Basic 2 For Windows only
1993 Visual Basic 3 For Windows only; enhanced with data access capability
1996 Visual Basic 4 For 16 bit or 32 bit Windows systems
1997 Visual Basic 5 For 32 bit Windows systems only
1998 Visual Basic 6 For 32 bit Windows systems only
2001 Visual Basic.NET Object oriented; sweeping overhaul
2005, 2008 Visual Basic (year) Further improvement and enhancement; convenience for developers
Last change: February 13 2016 18:48:20.