Re: using GET_KBRD [message #8363 is a reply to message #8305] |
Mon, 03 March 1997 00:00  |
pit
Messages: 92 Registered: January 1996
|
Member |
|
|
In article <33150043.7B48@wam.umd.edu>,
Walid Atia <atia@wam.umd.edu> writes:
> Hello All,
>
> I have what should be a simple problem. The following 3-line program:
>
> REPEAT BEGIN
> A = GET_KBRD(0)
> PRINT, BYTE(A)
> ENDREP UNTIL A EQ 'q'
>
> exits when the user types 'q'. However, remove the print statement,
> and the program runs indefinitely regardless of any user input!
>
> Anyone know what's wrong. I'm running IDL 4.0.1 on a PC.
Works here (also PC, Linux), but with some delay, i.e. you have to press
the "q" for a while until something happens. Not very nice, indeed.
Maybe change the GET_KBRD to GET_KBRD(1), then it waits until a key is
pressed, or insert a short wait, then it also works as expected.
Peter
--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~
Peter "Pit" Suetterlin http://www.uni-sw.gwdg.de/~pit
Universitaets-Sternwarte Goettingen
Tel.: +49 551 39-5048 pit@uni-sw.gwdg.de
-- * -- * ...-- * -- * ...-- * -- * ...-- * -- * ...-- * -- * ...-- * --
Come and see the stars! http://www.kis.uni-freiburg.de/~ps/SFB
Sternfreunde Breisgau e.V. Tel.: +49 7641 3492
____________________________________________________________ ______________
|
|
|