...

View Full Version : C++ -> What is the pressed key ?



Active X
10-29-2007, 09:34 AM
Hello to dear developers reading this message .

I want to handle the Keypress event in C++ . I know C++ doesn't have handler but I can simulate it like this :

while (condition)
{
char inputChar = What should I write here ?;
if (inputChar == 'A')
{
// Program code goes here .
}
}

I'll be waiting for solutions of you , the masters of C++ .

Will be thankful to any help .

oracleguy
10-29-2007, 07:04 PM
Look into using getch() it will do what you want.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum