Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ getch(DOS) — Xenix 2.3.4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

cgets(DOS)

getche(DOS)

getchar(S)



     GETCH(DOS)               XENIX System V                GETCH(DOS)



     Name
          getch - Gets a character.

     Syntax
          #include <conio.h>

          int getch ( );

     Description
          The getch function reads, without echoing, a single
          character directly from the console.  Characters typed are
          not echoed.  If a CONTROL-C is typed, the system executes an
          INT 23H (CONTROL-C exit).

     Return Value
          getch returns the character read.  There is no error return.

     See Also
          cgets(DOS), getche(DOS), getchar(S)

     Example
          #include <conio.h> #include <ctype.h>

          int ch;

          /* This loop gets characters from the keyboard until a **
          non-blank character is seen. Preceding blank ** characters
          are discarded.  */

          do   {      ch = getch ( );      } while (isspace (ch));

     Notes
          This call must be compiled with the -dos flag.






















     Page 1                                           (printed 8/7/87)



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026