Hello, Student Question,

What i desire to be able to do is check if there is a charecter pending for input in a console application without the thread going blocked, for example

<code>
while(true)
{
if (isCharWaiting())
{ Console.Read() // process the char }
// otherwise select check network sockets
} // loop
</code>

Console.In appears to be a TextReader and has a method Peek(), but this method seems to always block the thread waiting for input wheather set to Line or Char input mode with "SetConsoleMode" API.

I also tried using the "GetNumberOfConsoleInputEvents" API but even when checking if the EventType was a KEY_EVENT this still seems to leave events for keys depressing and releaseing that do not ultimately result in charecters being added to the Console.In and hence result in going IO blocked.

Im thinking i may have gone down a totally wrong route to solving this problem and would be grateful if someone could point me in the right direction, thank you

Brian