prompt2

Creates a box for prompt text.

Available in:

Apps (win) Apps (char) Reportwriter RPC Standalone PL
X X X X  

Syntax

string prompt2(row,col,text[,text...],field-text,len,visual,box)
int            row,col,len,visual,box
string         text,field-text

Description

Returns user input.
row specifies the row position for the displayed window. -1 places the upper left of the box at the cursor position. -2 places the box in the center of the screen.

col specifies column location of the view box; -1 places the upper left of the box at the cursor position. -2 places the box in the center of the screen.

text (optional) specifies one or more text lines.

field-text specifies text to be placed in field.

len specifies the length of text field.

visual specifies visual attribute of field.

box allows you to draw a box around prompt. If this value is true (nonzero), the function draws a box.

Notes

The number of text lines and the last text plus len determine the box size. The field is placed after the last text line. Keys 0 and 3 return except if len is 1, in which case all keys return. The prompt window is always closed on exit. Use refresh(false) to give the appearance of remaining open if needed for error handling.