Handbook: Difference between revisions

From NSB App Studio
Jump to navigation Jump to search
(Created page with "2.1 Conventions Used in this Handbook The following notation conventions are used in this Handbook: KEYWORDS Capital letters indicate NS Basic/App Studio keywords and other t...")
 
(Replaced content with "<div class="center" style="width:auto; margin-left:auto; margin-right:auto;">'''CONTENTS'''</div> ----")
Line 1: Line 1:
2.1 Conventions Used in this Handbook
<div class="center" style="width:auto; margin-left:auto; margin-right:auto;">'''CONTENTS'''</div>
The following notation conventions are used in this Handbook:
----
KEYWORDS
Capital letters indicate NS Basic/App Studio keywords and other text that must be typed exactly as shown. For the purposes of this manual, uppercase text indicates a required part of the Statement syntax. NS Basic/App Studio is case-insensitive: keywords are accepted with either uppercase letters, lowercase letters, or any mixture of the two. A keyword such as PRINT may be entered into your programs as print, Print, or PRINT.
placeholders
Italic text indicates a placeholder for types of information that you must supply. In the following Statement, expression is italicized to show that the EXECUTE statement requires an expression:
EXECUTE expression
    Example
This Monaco typeface indicates example program code and information that is printed on your NS Basic/App Studio screen. The following example shows a line from an NS Basic/App Studio program:
PRINT "Hello World!"
 
[Optional]
Brackets indicate that the enclosed items are optional. In the following example, brackets are used to show that entering a second item to display on the screen is optional for the PRINT statement:
PRINT expression1 [ ,expression2 ]
Both of these PRINT statements are legal, since PRINT accepts up to 20 expressions:
PRINT "Hello"
PRINT "Hello","World"
 
|
The vertical bar indicates that the items are mutually exclusive. In the following example the bar indicates that the LEN function can either be used with a string or a variable name:
LEN(string | variable)
2.2 The Elements of an NS Basic/App Studio Program
A program in NS Basic/App Studio is a set of Statements. Each NS Basic/App Studio program line may consist of the following elements:
KEYWORD arguments 'comment
A KEYWORD is a word from the language that NS Basic/App Studio understands. Examples are PRINT, INPUTBOX and IF. The Statement and its arguments determine what action (if any) will be taken by NS Basic/App Studio when the line is executed.
Any text following ' on a line is a comment, and is ignored by NS Basic/App Studio.
2.2.1 Multi-Line Statements
Each NS Basic/App Studio statement normally ends at the end of the statement line. If you have a very complex statement the line can be very long. This can make your programs difficult to read. You may split long statements by using the line-continuation sequence, a space followed by an underscore, ( _) at the end of the

Revision as of 01:11, 1 August 2012

CONTENTS