Difference between revisions of "NEXTKEY()"

From Recital Documentation Wiki
Jump to: navigation, search
 
(One intermediate revision by one user not shown)
Line 1: Line 1:
==Class==
 
Keyboard Events
 
 
 
 
==Purpose==
 
==Purpose==
 
Function to return the integer numeric value of a key press
 
Function to return the integer numeric value of a key press
Line 29: Line 25:
  
 
==Products==
 
==Products==
Recital Mirage Server, Recital Terminal Developer
+
Recital  
 
[[Category:Documentation]]
 
[[Category:Documentation]]
 
[[Category:Functions]]
 
[[Category:Functions]]
 
[[Category:Keyboard Events]]
 
[[Category:Keyboard Events]]
 
[[Category:Keyboard Events Functions]]
 
[[Category:Keyboard Events Functions]]

Latest revision as of 17:22, 3 December 2009

Purpose

Function to return the integer numeric value of a key press


Syntax

NEXTKEY()


See Also

INKEY(), LASTKEY(), ON ESCAPE, ON KEY, READKEY(), SET KEY, SET PCKEYS, SLEEP


Description

The NEXTKEY() function returns an integer numeric value for the next key pressed at the keyboard, without removing it from the keyboard buffer. The command SET PCKEYS is used to change to return value of the NEXTKEY() function. When SET PCKEYS is OFF, the NEXTKEY() function returns the ASCII code for the key that was pressed. When SET PCKEYS is ON, the NEXTKEY() function returns the IBM PC keyboard value of the key that was pressed. If no key is pressed, the NEXTKEY() function returns 0.


Example

do while nextkey()=0
    @0,68 say ampm()
    sleep 2
enddo


Products

Recital