Skip to Content
Programming Visual Basic .NET, Second Edition
book

Programming Visual Basic .NET, Second Edition

by Jesse Liberty
April 2003
Intermediate to advanced
560 pages
14h 4m
English
O'Reilly Media, Inc.
Content preview from Programming Visual Basic .NET, Second Edition

Statements

In Visual Basic .NET a complete program instruction is called a statement . Programs consist of sequences of Visual Basic .NET statements. Each statement must end with a new line:

Dim x As Integer       ' a statement
x = 23                 ' another statement
Dim y As Integer = x   ' yet another statement

It is possible to combine two (or more) statements on a single line by separating the statements with the colon operator:

Dim x As Integer = 23 : Dim y As Integer = 25

While this is legal, it is uncommon because it makes the code more difficult to read.

A statement that evaluates to a value (e.g., to a Boolean value) is called an expression .

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Programming Visual Basic .NET

Programming Visual Basic .NET

Dave Grundgeiger
VB.NET Language in a Nutshell, Second Edition

VB.NET Language in a Nutshell, Second Edition

Steven Roman PhD, Ron Petrusha, Paul Lomax

Publisher Resources

ISBN: 0596004389Supplemental ContentCatalog PageErrata