Line Label (program): Difference between revisions

From BR Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 11: Line 11:
  00300 GOTO BIG
  00300 GOTO BIG


For information about the labels that are used in procedures, see [[Line Label (Procedure)]].
For information about the labels that are used in procedures, see [[Line Label (procedure)]].





Revision as of 22:42, 5 February 2013

The Line label is an optional name for a program line. They are accepted at the beginning of all statements following the line number. The label may be from one to 30 alphabetic, numeric or underscore characters in length, but must begin with a letter. Each line label must be unique and immediately followed by a colon. Business Rules allows most statement and command keywords to be used as line labels. In the following statement, "LABEL_SAMPLE:" is a line label:

00900 LABEL_SAMPLE: Rinput #1, Select '2,40,Cr 10,[w]',Attr "[A]": Autoselect$

A line label can then subsequently be used in place of a line number to reference the line from a secondary expression. In the following example, the line label BIG is defined to represent line 120; it is then used as a line reference for the GOTO statement in line 300. (F1 is also a line label):

00120 BIG: Print Using F1: A$,T(5)
o
o
o
00300 GOTO BIG

For information about the labels that are used in procedures, see Line Label (procedure).