Hey fellas, I just found out that this nifty little command would help me capture the ALT key in my program. Question is, how exactly do I use this command to capture the key?
Lemme know if this makes sense:
if (GetAsyncKeyState(VK_ALT))
//do whatever
Because, I'm thinking that I will have to setup a loop to actually catch the ALT keypress. Won't I? I mean it's not like getch() that will wait on the user to enter something. Something to the effect of:
while (GetAsyncKeyState(VK_ALT))
//do whatever
Won't I? Or am I just typing nonsense here?
MSDN doesn't show me any examples of it's usage in C. Thanks in advance.