Search the FAQ Archives

3 - A - B - C - D - E - F - G - H - I - J - K - L - M
N - O - P - Q - R - S - T - U - V - W - X - Y - Z
faqs.org - Internet FAQ Archives

comp.os.msdos.programmer FAQ part 2/5
Section - - How can I read a character without echoing it to the screen, and without waiting for the user to press the Enter key?

( Part1 - Part2 - Part3 - Part4 - Part5 - Single Page )
[ Usenet FAQs | Web FAQs | Documents | RFC Index | Property taxes ]


Top Document: comp.os.msdos.programmer FAQ part 2/5
Previous Document: Section 4. Keyboard
Next Document: - How can I find out whether a character has been typed, without waiting for one?
See reader questions & answers on this topic! - Help others by sharing your knowledge
Date: 5 Feb 2002 22:03:03 -0400

 The C compilers from Microsoft and Borland offer getch() (or getche() to
 echo the character); Turbo Pascal has ReadKey.

 In other programming languages, execute INT 21 AH=8; AL is returned with
 the character from standard input (possibly redirected). If you don't
 want to allow redirection, or you want to capture Ctrl-C and other
 special keys, use INT 16 AH=10; this will return the scan code in AH and
 ASCII code (if possible) in AL, but AL=E0 with AH nonzero indicates that
 one of the gray "extended" keys was pressed. (If your BIOS doesn't
 support the extended keyboard, use INT 16 AH=0 not 10.)

User Contributions:

Comment about this article, ask questions, or add new information about this topic:

CAPTCHA




Top Document: comp.os.msdos.programmer FAQ part 2/5
Previous Document: Section 4. Keyboard
Next Document: - How can I find out whether a character has been typed, without waiting for one?

Part1 - Part2 - Part3 - Part4 - Part5 - Single Page

[ Usenet FAQs | Web FAQs | Documents | RFC Index ]

Send corrections/additions to the FAQ Maintainer:
jeffrey@carlyle.org (Jeffrey Carlyle)





Last Update March 27 2014 @ 02:11 PM