HP Business BASIC/XL Reference Manual - HP 3000 MPE/iX Computer Systems - Edition 1 (32715-90001)

6- 3
||||||
---------------------------------------------------------------------------------------------
Input Prompt
This section explains how prompts are displayed when HP Business BASIC/XL
is running interactively. Input prompts are not displayed if HP Business
BASIC/XL is running in a job stream.
A prompt can be supplied for each input element except within a FOR
clause. The default prompt is a question mark.
Table 6-4 shows how the prompt option and the separator that follows
affect the cursor position.
Table 6-4. Effect of Input Prompt and Separator on Cursor
---------------------------------------------------------------------------------------------
|| || |
| Is Prompt | Prompt that | Separator | Where HP Business BASIC/XL |
| Supplied? | HP Business BASIC/XL | Following | Puts the Cursor After |
||Uses | Prompt | Printing the Prompt and Putting |
|| ||the Program in the Input State |
|| || |
---------------------------------------------------------------------------------------------
|| || |
| Yes | The prompt that was | ; | HP Business BASIC/XL does not move |
| | supplied. | | the cursor. |
|| || |
---------------------------------------------------------------------------------------------
|| || |
| Yes | The prompt that was | , | At the beginning of the next line. |
| | supplied. | | |
|| || |
---------------------------------------------------------------------------------------------
|| || |
| Yes | The prompt that was | None | At the beginning of the next line. |
| | supplied. | | |
|| || |
---------------------------------------------------------------------------------------------
|| || |
| No | Question mark (?). | Not | At the beginning of the next line. |
| | | applicable | |
|| || |
---------------------------------------------------------------------------------------------
Interactive Input from a Terminal
This section explains how to enter input when HP Business BASIC/XL is
running interactively. The rules for input from a keyboard also apply to
input from an input file.
After the INPUT statement displays a prompt and puts the program into the
input state, you can type values on the terminal keyboard. Individual
values are separated by commas or semicolons. If numeric values are
expressed in European format where either a comma or period is the radix
indicator, then input values must be separated with semicolons.
Double quotes surrounding string values are optional. The string must be
enclosed in quotes if it contains a comma, a semicolon, or leading or
trailing blanks. Otherwise, these symbols are interpreted as item
separators. If a string value that is enclosed in quotes contains a
quote, the quote that it contains must be duplicated; for example, the
unquoted string
"Hi," he said.
must be quoted (because it contains a comma), and the quotes that it
contains must be duplicated:
"""Hi,"" he said."