Detecting input of function keys

Hello all,

Can you please help me in trying to detect the input of function keys such as F2 F3... Home End and arrow keys in pascal please?

Thank you very much
Chris.

Comments

  • : Hello all,
    :
    : Can you please help me in trying to detect the input of function keys such as F2 F3... Home End and arrow keys in pascal please?
    :
    : Thank you very much
    : Chris.
    :
    You need the ReadKey() function for that. It can read any key press and returns 1 byte of the key-code for it. Function keys have 2 byte key codes, so you need to have 2 calls to ReadKey(). The first byte will always be #0, while the other is non-zero.
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

In this Discussion