CT_SCANKEY

 SCANKEY()
 Queries scan code of keyboard input
------------------------------------------------------------------------------
 Syntax

     SCANKEY([<lMode>]) --> nKeyValue

     Warning!  Augmented from Clipper Tools.  This is new optional
     parameter.

 Argument

     <lMode>  Designates whether or not to ignore the additional keys on
     the European extended keyboard.

 Returns

     SCANKEY() returns the scan code for the key pressed.

 Description

     SCANKEY() returns an untranslated scan code for a key.  This allows you
     to differentiate between keys or key combinations that return the same
     INKEY() value.  SCANKEY() does not take the character out of the buffer.
     The function waits for a keyboard input and returns the scan code which
     corresponds.  The third example shows how a returned value is converted
     into something you can display, as in CTSCAN.CH by SCANKEY().  Although
     it depends on the keyboard, the scan codes may differ from those listed
     in CTSCAN.CH.

 Note

     .  No key traps (including the Clipper internal key traps),
        are acknowledged.

 Examples

     .  Return with input of Ctrl-W:

        ? INKEY()                // 23
        ? SCANKEY()              // 4375
        ? NUMLOW(SCANKEY())      // 23
        ? NUMHIGH(SCANKEY())     // 17

     .  When inputting Ctrl-End (numeric key pad), return:

        ? INKEY()                // 23
        ? SCANKEY()              // 29952
        ? NUMLOW(SCANKEY())      // 0
        ? NUMHIGH(SCANKEY())     // 117

     .  Reuse codes with other functions:

        nCode  :=  SCANKEY()
        SETKXLAT(CHR(NUMLOW(nCode)) * CHR(NUMHIGH(nCode)), -1)

See Also: NUMHIGH() DSETKBIOS()



Tools – Miscellaneous Functions

Introduction Miscellaneous Functions
ALLOFREE()*  Determines the maximum memory size allocation
BLANK()      Creates a blank value for each data type
COMPLEMENT() Forms the complement value of a data type
DATATYPE()*  Determines the data type of a variable or UDF
GETTIC()     Determines the number of timer ticks
KBDDISABLE() Locks/unlocks the keyboard
KBDEMULATE() Inserts characters into BIOS keyboard buffer to emulate input
KBDSPEED()   Sets keyboard auto repeat speed
KBDSTAT()    Tests for key shift state status, such as Ctrl and Shift
KBDTYPE()    Determines the type of keyboard in use
KEYSEC()     Triggers a key trap after a time delay
KEYTIME()    Triggers a key trap at a specific clock time
MILLISEC()   Time delay in milliseconds
NUL()        Converts the value returned by a function into a null string
SCANKEY()    Queries scan code of keyboard input
SETTIC()     Increases number of time ticks
SHOWKEY()    Continuously displays the INSERT and LOCK status
SOUND()      Creates tones (melodies) by designating frequency and duration
SPEED()      A comparison value used to determine the processor speed
STACKFREE()  Determines the remaining stack space
TOOLVER()    Queries the version number of the Clipper Tools in use
XTOC()       Converts an expression of any data type into a string