Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!cunixf.cc.columbia.edu!cubmol!ping From: ping@cubmol.bio.columbia.edu (Shiping Zhang) Newsgroups: comp.lang.c Subject: Re: Keys Message-ID: <1990Aug17.025921.15369@cubmol.bio.columbia.edu> Date: 17 Aug 90 02:59:21 GMT References: <1990Aug16.160043.20584@eagle.lerc.nasa.gov> <1990Aug16.214621.9896@NCoast.ORG> Reply-To: ping@cubmol.bio.columbia.edu (Shiping Zhang) Organization: Dept. of Biology, Columbia Univ., New York, NY Lines: 13 In article <1990Aug16.160043.20584@eagle.lerc.nasa.gov> vvcns@mars.lerc.nasa.gov writes: > I was wondering if anybody knows how to make a program accept input >from the keyboard without the user pressing the return key. For example, >if a user is asked a yes or no question and s/he types a y, the program >will continue as if return was pressed. I am working on a VAX/VMS system >v5.1. I would appreciate any help. Have you ever tried to use ioctl()? This function can be used to set the terminal into the "raw" mode. With this mode, characters are readable immediately. -ping