Advertisement

Quick Windows Console question

Started by June 02, 2002 01:30 PM
1 comment, last by CoderX 22 years, 5 months ago
Hi guys, I have this console app runnning and it seems that windows only processes it whenever the keyboard is pressed or the mouse is moving inside the console window. How can I make it be active all the time? I have this while loop which draws characters on screen, and it only does it when the mouse is moved inside or keybaord is pressed.
++postcount;
Try this above your input:

if(WAIT_TIMEOUT == WaitForSingleObject(hInput, 20)) 


Jeff D
Suffered seven plagues, but refused to let the slaves go free. ~ Ross Atherton
Advertisement
Thanks, I tried your code and it wouldn''t accept any input so I went to MSDN and checked it out, and replaced it with WAIT_OBJECT_0 and now it works fine. I know how it works but still confused as to why it wouldn''t do that in the first place.

Thanks again.
++postcount;

This topic is closed to new replies.

Advertisement