[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Arrow Keys

Posted on 1998-08-14
1
Medium Priority
?
337 Views
Last Modified: 2010-04-15
Need a source code that uses arrow keys.
0
Comment
Question by:Nene19
1 Comment
 
LVL 16

Accepted Solution

by:
imladris earned 150 total points
ID: 1252122
int c,arrow;

arrow=0;
c=getch();
if(c==0)arrow=getch();
if(arrow!=0)
{    .....
}


if arrow is 72 it is UP, if it is 80 it is DOWN
if it is 75 it is LEFT, if it is 77 it is RIGHT

0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you thought about creating an iPhone application (app), but didn't even know where to get started? Here's how: ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ Important pre-programming comments: I’ve never tri…
An Outlet in Cocoa is a persistent reference to a GUI control; it connects a property (a variable) to a control.  For example, it is common to create an Outlet for the text field GUI control and change the text that appears in this field via that Ou…
The goal of this video is to provide viewers with basic examples to understand and use pointers in the C programming language.
The goal of this video is to provide viewers with basic examples to understand how to use strings and some functions related to them in the C programming language.
Suggested Courses
Course of the Month17 days, 23 hours left to enroll

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question