Difference between revisions of "WAIT"

From Recital Documentation Wiki
Jump to: navigation, search
Line 31: Line 31:
 
The WAIT command displays the specified prompt <expC> on the screen and suspends program execution until a key is pressed.  If no <expC> is specified, then "Press any key to continue..." is displayed.  The key that is read from the keyboard is not echoed.
 
The WAIT command displays the specified prompt <expC> on the screen and suspends program execution until a key is pressed.  If no <expC> is specified, then "Press any key to continue..." is displayed.  The key that is read from the keyboard is not echoed.
  
CLEAR
+
====CLEAR====
 
The CLEAR keyword will remove a system window or window message when the WAIT command is called from a program.
 
The CLEAR keyword will remove a system window or window message when the WAIT command is called from a program.
  
NOWAIT
+
====NOWAIT====
 
The NOWAIT keyword will create a message like the Recital/4GL system message, which is displayed in the upper right hand corner.  A message created with the NOWAIT keyword does not discard the keystroke you use to remove the message.
 
The NOWAIT keyword will create a message like the Recital/4GL system message, which is displayed in the upper right hand corner.  A message created with the NOWAIT keyword does not discard the keystroke you use to remove the message.
  
TIMEOUT <expN>
+
====TIMEOUT <expN>====
 
The TIMEOUT clause lets you specify the number of seconds, <expN>, the message will remain on the screen before the program execution continues.  This is provided for Xbase language compatibility only.
 
The TIMEOUT clause lets you specify the number of seconds, <expN>, the message will remain on the screen before the program execution continues.  This is provided for Xbase language compatibility only.
  
TO <memvar>
+
====TO <memvar>====
 
If the optional TO <memvar> clause is specified, then the key that is pressed is stored as a character string in the designated memory variable.  If the [RETURN] key is pressed, or the key which is pressed does not represent a printable character, then a null string, "", is stored in the memory variable.    If the memory variable does not exist, it is created.
 
If the optional TO <memvar> clause is specified, then the key that is pressed is stored as a character string in the designated memory variable.  If the [RETURN] key is pressed, or the key which is pressed does not represent a printable character, then a null string, "", is stored in the memory variable.    If the memory variable does not exist, it is created.
  
WINDOW
+
====WINDOW====
 
The WINDOW keyword will cause the message to be displayed in the system message window.
 
The WINDOW keyword will cause the message to be displayed in the system message window.
  

Revision as of 10:25, 16 March 2009

WAIT

Class

Keyboard Events


Purpose

Suspend program execution until a key is pressed at the keyboard


Syntax

WAIT [<expC>]

[CLEAR]

[NOWAIT]

[TO <memvar>]

[TIMEOUT <expN>]

[WINDOW]


See Also

ACCEPT, @...GET, DIALOG BOX, INPUT, MESSAGE, READ


Description

The WAIT command displays the specified prompt <expC> on the screen and suspends program execution until a key is pressed. If no <expC> is specified, then "Press any key to continue..." is displayed. The key that is read from the keyboard is not echoed.

CLEAR

The CLEAR keyword will remove a system window or window message when the WAIT command is called from a program.

NOWAIT

The NOWAIT keyword will create a message like the Recital/4GL system message, which is displayed in the upper right hand corner. A message created with the NOWAIT keyword does not discard the keystroke you use to remove the message.

TIMEOUT <expN>

The TIMEOUT clause lets you specify the number of seconds, <expN>, the message will remain on the screen before the program execution continues. This is provided for Xbase language compatibility only.

TO <memvar>

If the optional TO <memvar> clause is specified, then the key that is pressed is stored as a character string in the designated memory variable. If the [RETURN] key is pressed, or the key which is pressed does not represent a printable character, then a null string, "", is stored in the memory variable. If the memory variable does not exist, it is created.

WINDOW

The WINDOW keyword will cause the message to be displayed in the system message window.


Example

@23,0
wait "Enter your selection..." to option


Products

Recital Mirage Server, Recital Terminal Developer