Computing.Net > Forums > Programming > C keys

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

C keys

Reply to Message Icon

Name: afnhe
Date: December 6, 2005 at 11:47:21 Pacific
OS: Gnu/Linux
CPU/Ram: athlon xp 1700+ 512 MB
Comment:

Hi, how can i do when the escape key(ESC) is pressed do some action (go to a function for example)? Thanks.



Sponsored Link
Ads by Google

Response Number 1
Name: Fel
Date: December 7, 2005 at 01:54:44 Pacific
Reply:

input = getch();

if (input == 27)//27 is ASCII key for ESC
{
//do something, example
exit();
}

Athlon 64 2800+ @ 2.63 Ghz Stock Cooling
Timings:2-3-2-5
V-Gen 512MB pc3200
DFI Lanparty UT NF3
Abit R9550 VGuru XTurbo
525Mhz/300Mhz


0
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: C keys

Bat File edit text file www.computing.net/answers/programming/bat-file-edit-text-file/1653.html

Multimedia Keys in C++ www.computing.net/answers/programming/multimedia-keys-in-c/4163.html

log key strokes - VB, c++, asp, php www.computing.net/answers/programming/log-key-strokes-vb-c-asp-php/16584.html