Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
Keyword Syntax
◄Contents► ◄Index► ◄Back►
──────────────────────────────────────────────────────────────────────────────
Keyword Syntax
■ Visual Basic uses the following syntax conventions for keywords:
Item Description
══════════════════ ═════════════════════════════════════════════════════
KEYWORD Items in capital letters(1) indicate Visual Basic
reserved words: statements, functions, and other
keywords that are a required part of the syntax,
unless they are enclosed in brackets. You must spell
keywords correctly. See: ◄Visual Basic Reserved Words►
argument Items in lowercase are placeholders for information
you must supply in the statement, such as a file,
form, or control name.
[item] Items inside square brackets are optional; you do not
have to use them in the statement.
{this | that} Braces and a vertical bar indicate a choice between
two or more items. You must use one of the items in
the statement unless the braces are enclosed in
square brackets.
item, item, ... Ellipses indicate that more of the preceding items can
be used in a single-line statement.
beginning KEYWORD Vertical ellipses are used to describe multiline or
. block-structured statements; other statements can be
. used between the beginning and the end of the block.
.
ending KEYWORD
─────────────────────────────────────────────────────────────────────────
(1) Uppercase and lowercase syntax conventions are used to help you read
the syntax rules for a statement. They are not capitalization rules.
■ Here is an example of the PRINT method syntax:
[form.][picturebox. | PRINTER.]PRINT [USING formatstring$;]
[expressionlist] [{,|;}]
• form Optional reference to the name of the form; if
omitted, implicit form reference is used
• picturebox Optional reference to name of picture box control;
if omitted, implicit form reference is used
• PRINTER Optional reference to PRINTER object
• PRINT Required keyword
• USING formatstring$ Optional USING keyword followed by formatstring
• expressionlist Optional expressionlist to print
• , | ; Separators to choose from when specifying
multiple expressions
■ The following PRINT statements are all syntactically correct:
PRINT
PRINT x
PRINT x, y + 1
PRINT x,
PRINT x;
PRINT x + y + z, a - 1, b / 2;
See: ◄Shortcut Keys► ◄Using Dialog Boxes►
◄Using Menus and Commands► ◄Using Help►