Visual Basic (VB) bears little resemblance to earlier BASIC languages. Mechanisms are built into VB that improve semantic clarity and ensure semantic validity of program code.
VB is a structured language - GOTOs are not required because control structures are available. VB is a strongly typed language - variables must belong to a specific type (if you don't declare a variable as a specific type the variable is of variant type). VB takes care of variable initialization, preventing a common semantic error that occurs when you use a uninitialized variable.
The syntax of the language has been expanded with each version, while maintaining restrictions on features that would give the language more access to Windows' system functions but would also make the language inappropriate for application development. For example, VB allows coherent assignment of compound objects (arrays, classes), but does not have unsigned integers and its type safety interferes with bit shifting.
With VB .Net the language is now fully object-oriented. Versions 4 through 6 grew more object oriented with nearly every version: classes appeared in VB 4.0, polymorphism (with the Implements key word) in VB 5.0. Implementation inheritance appeared with VB .Net.
Print Preview - Demonstrates how to add Print Preview functionality to a VB application.
System Tray Icon - Shows how to use AddressOf instead of a subclassing control to add an icon to the system tray.
Four criteria must be implemented by any language that is fully object-oriented:
| Name | Rating | Description |
|---|---|---|
| VB Home | Best | Microsoft's Visual Basic Home |
| FAQ | Hot Issues, Service Packs or Hotfixes, Setup and Conversion, General Information |
| Name | Rating | Description |
|---|---|---|
| MSDN | Best | Microsoft's MSDN Home |
| Desaware | Best | Desaware's site - best reference articles |
| Kurata | Good | Deborah Kurata's site |
| Carl Peterson | Carl Peterson's site | |
| DevX | Mixed Bag | Discussion forums, articles, code, product demos |
| PT | N/A | ProgrammingTutorials |
| Name | Rating | Description |
|---|---|---|
| VBnet | Best | The best source for code, techniques and how-to information for Visual Basic. |
| VB Accelerator | Very little trash ad and they get right to the point with code and documentation. | |
| VBExplorer | Good | Code, FAQ, tutorials, forums |
| CodeCranker | Good | Dr. Dobb's DevSearcher, their Programmer's Search Engine |
| VB Town | Mixed Bag | This site used to be ok, but now it has far too many spam ads |
| VB Thunder | OK | VB Thunder |
| AndreaVB | Andrea's VB site - articles and code, useful message board | |
| VB2themax | VB 2 the max | |
| TheScarms | Code library covering Visual Basic and Win32 APIs. Discussions, screen shots, Windows and registry tips, etc. | |
| PlanetSource | ||
| VB helper | Code tips, books, links |
| Name | Rating | Description |
|---|---|---|
| VB Square | Good | Now developer.com |
| CodeArchive | Good | CodeArchive |
| Matthart | Good | Another good VB site - it seems there is no end to them. |
| VB Techniques | Mixed Bag | Articles, tips, forum |
| VB Source | Mixed Bag | VB Source |
Most of the examples described on this page were developed by the author, Gregory Swanson.
Microsoft® Visual Basic Help was used often while developing the examples on this page.
Appleman, Daniel, 1996, Visual Basic Programmer's Guide to the Win32 API: Ziff-Davis Press,
1,518 pages. ISBN 1-56276-287-7
Detailed information on using the Win32 API in Visual Basic.
Robichaux, Paul, 2000, Managing the Windows 2000 Registry: O'Reilly & Associates, Inc.,
541 pages. ISBN 1-56592-943-8
Details on the proper use of Windows' registry API.