Thread: Array of possible keys that can be pressed

  1. #1
    Registered User
    Join Date
    Nov 2002
    Posts
    41

    Array of possible keys that can be pressed

    Hey, can anyone give me the array that holds all the possible keys that could be pressed, and a few examples of the keys if its in a format of some kind, thanx

  2. #2
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    Posts
    14,826
    Keystrokes are just integers. Extra keys (F1, F2, Right-Arrow, etc) are actually two keystrokes. Valid keystrokes are 0 - 255. With combination keys, IIRC, the first "keystroke" is a zero, and then you read an additional "keystroke" which translates into the "real keystroke".

    Search the board or Google and you should find tons of examples on the topic.

    A slight correction on valid range, this is also dependant on what type of "character set" you're reading. Unicode? Well then you've got a whole different set of numbers. Visit google and this board's search function.

    Quzah.
    Hope is the first step on the road to disappointment.

  3. #3
    Registered User
    Join Date
    Nov 2002
    Posts
    41
    i found what i meant, i mean:

    KEY[KEY_ESC], this way i can use a do{ }while(KEY[KEY_ESC] for a quick exit
    In order of learned:
    HTML - Mastered
    CSS - Enough to use
    SSI - Mastered
    PHP - Advanced
    C/C++ - Current Project

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 7
    Last Post: 11-25-2008, 01:50 AM
  2. array of pointers/pointer arithmetic
    By tlpog in forum C Programming
    Replies: 18
    Last Post: 11-09-2008, 07:14 PM
  3. 1-D array
    By jack999 in forum C++ Programming
    Replies: 24
    Last Post: 05-12-2006, 07:01 PM
  4. Class Template Trouble
    By pliang in forum C++ Programming
    Replies: 4
    Last Post: 04-21-2005, 04:15 AM
  5. Quick question about SIGSEGV
    By Cikotic in forum C Programming
    Replies: 30
    Last Post: 07-01-2004, 07:48 PM