FunctionKeys
State = FunctionKeys(KeySelect)
 
Parameters:

    KeySelect = The Number of the Function key you wish to check
Returns:

    State = The state of the key (0= up, 1 = pressed)
 

      The FunctionKeys() function will return the state of either FUNCTION keys (F1 to F12) upon your keyboard.

      Since these keys are commonly used as game controls, they have their own dedicated command. Purely to make things easy to remember and your code easier to read.

      If the selected key is being pressed, the function will return a value of 1 (True), or a zero (False if it's not being pressed.




FACTS:


      * None



Mini Tutorial:


      This example shows how to read the function keys.

  
  Do
     Cls RGB(0,0,0)
     
   ; Display the Status of the 12 Function keys
     For lp=1 To 12
        Print "Function Key State:(F"+Str$(lp)+") = "+Str$(FunctionKeys(lp))
     Next lp
     
     
   ; Display the Screen and wait for the user to press a key
     Sync
  Loop
  
  




 
Related Info: AltKeys | BreakKey | CtrlKeys | Downkey | EnterKey | Esckey | FlushKeys | KeyState | Leftkey | Rightkey | Scancode | ShiftKeys | Upkey | WindowsKeys :
 


(c) Copyright 2002 - 2024 - Kevin Picone - PlayBASIC.com