O'Reilly logo

Microsoft® Access® 2010 Inside Out by Jeff Conrad and John Viescas

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Controlling the Flow of Statements

Visual Basic provides many ways for you to control the flow of statements in procedures. You can call other procedures, loop through a set of statements either a calculated number of times or based on a condition, or test values and conditionally execute sets of statements based on the result of the condition test. You can also go directly to a set of statements or exit a procedure at any time. The following sections demonstrate some of (but not all) the ways that you can control flow in your procedures.

Call Statement

Use a Call statement to transfer control to a subroutine.

Syntax

Call subroutinename [(<arguments>)]
or
subroutinename [<arguments>]

where <arguments> is

{[ByVal | ByRef] <expression> },...

Notes

The Call ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required