You are here: Development Standards > Routines > General Routines > GENSELIN.PUB

# GENSELIN.PUB

GENSELIN.PUB is a public program for output selection prompts. This program is called by GENOUT.PUB.

`XXXX ENTER PROMPT$,VAR$`

Variable | Description
PROMPT$ | Text to print as the prompt. The prompt should be a series of choices with the first character of each choice enclosed by parentheses (for example, "(P)rinter (F)ile").
VAR$ | Set to the letter selected from the prompt string

Exit Points | Explanation
EXIT | GENSELIN.PUB does not return an error.

GENSELIN.PUB searches the PROMPT$ string for parentheses. It keeps track of the position and value of the letters between the parentheses. To select an option, position the cursor at the letter of your choice. To move the cursor, use the arrow keys (which rotate between the choices) or press the first letter of your choice (the cursor moves to that letter) and then press Enter. The program exits with the selected value in VAR$.