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
Loading
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.
<<PreviousNext>>

Conventions for Syntax Specification

Syntax rules were mentioned in the previous subsection. In this textbook, when introducing new VB features, the rules for code are explained. The following table lists the conventions used in this text.

Syntax Rule Example Remark
Regular typed words represent exact words to be used in code. Option Strict On

Every word should be typed as it appears
Italicized letters represent a concept, a placeholder to be replaced with a specific item. Dim VariableName As Integer VariableName should be replaced with a variable name in actual coding.
Mutually exclusive alternatives are separated by vertical bars (“|”). ByRef|ByVal

Either ByRef or ByVal can be specified.
Items specified in brackets are optional. [ParameterList]

A parameter list can be present or omitted.
Brackets with items separated by vertical bars indicate one item or none can be specified. [ByRef|ByVal] Either ByRef or ByRef can be specified or omitted.
Braces with items separated by vertical bars indicate one item must be specified. {On|Off} Either On or Off must be specified.
The plus (+) sign indicates that two keys should be pressed at the same time. Ctrl+R The Ctrl key and the R key must be pressed simultaneously.
Ellipsis (…) indicates the omission of some parts. Dim Variable1 [As data type][, Variable2 [As data type]]... More can be specified.
Indentation: Four spaces are used for standard code indents. Two-space indents are used for statements that actually appear in one code line but have to span over two PDF lines. If A = B Then X = Y End If ‘This statement is actually in one code line The If block shows a standard code indent. When one code line has to span over two lines on a PDF page, a two space-indent is use to represent the continuation.
Last change: February 13 2016 18:48:20.
<<PreviousNext>>