PROGRAMMING SKILLS
Visual Basic Coding Standards

These notes formalise the coding standards when using Microsoft Visual Basic (VB),
or Microsoft Visual Basic for Applications (VBA). They apply whether customising
a Microsoft Access Database, or when using Microsoft Visual Basic to access a Microsoft
SQL Server Database.
A comprehensive Visual Basic coding standard encompasses all aspects of code construction
and, while the programmer should exercise prudence in its implementation, the guidelines
should be closely followed.
Why Have Coding Standards?
The main reason for using a consistent set of coding conventions is to standardise
the structure and coding style of a Visual Basic program so that the programmer
and others can easily read and understand the code. As maintenance costs are high,
it is essential to write code that can be easily deciphered and enhanced by anyone.
Good coding standards result in precise, readable, and unambiguous source code that
is consistent and as intuitive as possible. The object is to make the Visual Basic
program easy to read and understand without cramping the programmer's natural creativity
with excessive constraints and arbitrary restrictions.
Using solid coding techniques and good programming practices plays an important
role in software quality and performance. Errors are less likely to occur. By consistently applying a well-defined
coding standard and proper coding techniques, programmers working on a
software project are more likely to create a system that is easier to comprehend
and maintain.
Naming Conventions
Objects, Constants, Variables and Commands require well-formed naming conventions.
This note lists recommended conventions for these, and discusses the issues of identifying
data type and scope.
Coding Standards Listing
Click on the following links to view PDF files that can be saved or printed.
VB6 Coding Standards
VB.Net Coding Standards
(Still to be done - when I have a few spare hours!)
|