Futurebasic/Language/Reference/on expr gosub

From Wikibooks, open books for an open world
< Futurebasic | Language | Reference
Jump to: navigation, search

Contents

[edit] ON <expr> GOSUB

[edit] Statement

(+) Appearance (+) Standard (+) Console

[edit] Syntax

ON expr GOSUB {"label1"|lineNum1}[,{"label2"|lineNum2}...]

[edit] Description

This statement calls one of the subroutines indicated by a label or a lineNum, according to the value of expr. If expr equals 1, then the subroutine at label1 or lineNum1 is called; if expr equals 2, then the subroutine at label2 or lineNum2 is called, and so on. If expr is less than 1, or greater than the number of label 's and lineNum 's in the list, then the ON <expr> GOSUB statement does nothing.

[edit] See Also

GOSUB; [[ON <expr&gt]]; GOTO; SELECT

Personal tools
Namespaces
Variants
Actions
Navigation
Community
Toolbox
Sister projects
Print/export