Your First Visual Basic Program
Welcome to Visual Basic!
A Simple Project
Using the Application Wizard
Adding Controls to Forms
Visual Basic Controls
Creating and Manipulating New Controls
Changing Design Time Control Properties
Visual Basic Built-in Controls
Control Design Tips
Understanding Events
Introducing Events
Event Procedures
The Form Load Event
The Form Resize Event
Command Button Click Event
Text Box Change Event
The Timer Control’s Timer Event
GotFocus/LostFocus Events
Is There More?
Working with Forms and Controls
Setting Properties at Run Time
Setting Form Properties
Setting Control Properties
Using ActiveX Controls
Adding ActiveX Controls to a Project
Using the MonthView ActiveX Control
Extra ActiveX Samples (On Your Own)
Creating and Using Menus
Menus in Visual Basic
Using the Menu Editor
Working with Menus
Manipulating Menus at Run Time
Reusing Menus
Creating Popup Menus (On Your Own)
Compiling and Distributing Applications
Finishing Touches
Project Properties
Native Code vs p-code
Creating Your Executable
Using the Package and Deployment Wizard
Working with VBA
Creating a Simple Procedure
Variables and Parameters
Data Types
Using Constants
Investigating Built-In Functions
Branching Structures
Looping Structures
More Complex Looping Examples (On Your Own)
Handling Errors
Handling Syntax Errors
Handling Run-Time Errors
The Error Handling Standard
Taking a Closer Look
Who Handles Errors?
Debugging Applications
Handling Logic Errors
Watch Expressions
The Call Stack
The Debugging Process
More VBA Issues
Scope, Lifetime, and Precedence
Passing by Value and by Reference
Arrays
Optional Arguments
More Form and Control Issues
Using Multiple Forms
List Boxes Revisited
Control Arrays
Adding Simple Database Support
Support for Data Access in Visual Basic 6.0
Using the ADO Data Control
Binding Controls to Data
Writing Code for the Data Control