Click to See Complete Forum and Search --> : C Question.


nobby
12-13-2000, 05:31 AM
Does anyone know how to receive a single char input w/o having having to press Enter afterwards?

I thought it would be something like,

fprintf(stdprn, "whatever the message is");

which would print to the local printer. But I get a msg regarding stdprn, when I get back home I can give complete error msg.

Any inf0 would be great

Thanks

n0bbY

TheLinuxDuck
12-13-2000, 10:21 AM
Hey n0bbY,

http://www.linuxnewbie.org/ubb/Forum14/HTML/001634.html

Take a look at my first reply in this topic.. I wrote a simple single char input function and string input function using immediate buffer flushing, by changing the terminal setting, using the termios.h stuff. There is C code posted for doing exactly what you're wanting to do.

------------------
TheLinuxDuck
Wait... that's a penguin?!?!?
:wq